G
Guest
Hello,
In VBA, my code is importing from an XLS file, the format of which I don't
always know, as the columns which create the XLS are user definable.
What I am doing is importing that XLS into a temp table, which is created
during that import.
Here is the question: I then want to write a query which takes "certain"
fields I know are of interest, and use them in an append query. Of the 20
fields I need, the imported file may have more, but that's OK, as those
fields are not in the Append Query. The problem I have is this: Of the 20
fields I need, the use may not always included those in the XLS. Access asks
me for the value to use when it tries to append a field that does not exist.
So, I am looking for a good way to dynamically create the SQL/Query to be
based on those fields of interest that are actually in the imported table.
Thanks
-David
In VBA, my code is importing from an XLS file, the format of which I don't
always know, as the columns which create the XLS are user definable.
What I am doing is importing that XLS into a temp table, which is created
during that import.
Here is the question: I then want to write a query which takes "certain"
fields I know are of interest, and use them in an append query. Of the 20
fields I need, the imported file may have more, but that's OK, as those
fields are not in the Append Query. The problem I have is this: Of the 20
fields I need, the use may not always included those in the XLS. Access asks
me for the value to use when it tries to append a field that does not exist.
So, I am looking for a good way to dynamically create the SQL/Query to be
based on those fields of interest that are actually in the imported table.
Thanks
-David