I'm writing VBA code to open objects and document them. When it gets to a make-table query I'd like to get the fields of the table it makes along with each one's source. But when I set a QueryDef object to the make-table query, then set a Fields object to QueryDefObject.Fields, the collection is empty, i.e., its Count property is 0. I can't even get the name of the table it makes or the location (could be another database), and I can't guarantee that the table exists already.
I want to write up a log saying:
Make-table query "MyQuery" makes table "MyTargetTable" in "MyTargetDatabase"
MyTargetTable will have the following structure:
1. TargetField1/FieldType1/FieldSize1: source is SourceTable1/QueryField1
2. TargetField2/FieldType2/FieldSize2: source is SourceTable2/QueryField2
etc.
...even if MyTargetTable has never existed. Isn't this possible?
I want to write up a log saying:
Make-table query "MyQuery" makes table "MyTargetTable" in "MyTargetDatabase"
MyTargetTable will have the following structure:
1. TargetField1/FieldType1/FieldSize1: source is SourceTable1/QueryField1
2. TargetField2/FieldType2/FieldSize2: source is SourceTable2/QueryField2
etc.
...even if MyTargetTable has never existed. Isn't this possible?