msaccess-vcs-addin icon indicating copy to clipboard operation
msaccess-vcs-addin copied to clipboard

VCS 4.0.34: Unhandled error when exporting missing linked table

Open HughWarrington opened this issue 11 months ago • 4 comments

-------------------------------------
my_database.mdb
VCS Version 4.0.34
Performing Full Export
22/03/2024 13:30:09
-------------------------------------

Running with debug enabled.

image

image

I think the screenshots help explain what's going on.

It's trying to export data from a table. clsDbTableData.GetTableExportSql has generated a select query that is missing the ORDER BY columns at the end. I'm guessing this is because the table in question is a linked table that cannot be found on disk.

I'm not sure what the conventions are in this project (or in Access/VB in general) but perhaps we should instead log a meaningful warning saying 'missing linked table' or similar.

HughWarrington avatar Mar 22 '24 13:03 HughWarrington

Yes, it looks like we should test to ensure the table exists and is available before attempting an export of the data. Good idea!

joyfullservice avatar Mar 22 '24 15:03 joyfullservice

Added some code to ensure the availability of the target for linked tables, and logs the error more clearly for the user.

image

joyfullservice avatar Mar 22 '24 16:03 joyfullservice

Brilliant! Thank you.

HughWarrington avatar Mar 25 '24 22:03 HughWarrington

If this is working @HughWarrington, can you close it? Thank you!

hecon5 avatar Jun 26 '24 11:06 hecon5