G
Guest
I'm working in Access97 & DAO, unfortunately, as there are upgrade issues
stopping me from using something more up to date. Here's the problem I'm
having:
I'm updating data in a A97.mdb (lets say "archive.mdb") with info from a
..csv file, from code in another A97.mdb (lets say "control.mdb"). Control.mdb
has some static data tables in it. To do the transfer, I'm creating a temp
database in c:\temp, and linking the 3 parts of my data transfer to it as 3
linked tables - archive, source and, say, lookup. Now, I can do select and
delete queries on these tables just fine in DAO, and when I open this temp db
by hand I can do what I want to do by hand just fine using a query - insert
into archive select * from source where (condition on lookup). Doing this by
hand by means of a query is fine. Yet when I try to do the same thing using
DAO, it treats my query as a pass-thru query and wants a (ODBC)connection
string - I'm transferring data between 3 linked tables, so I can't see why it
is treating this as a pass-thru, when doing so manually appears to treat the
query as being an intra-database object.
I can code around this eg I can open the archive database and bring the data
into it directly, do my processing on it, and so on ... but I'd like to know
what is going on, and why it won't work doing it this way, in particular why
when I create queries by hand and by DAO there is the different treatment -
why the DAO ones are coerced into being pass-thrus. I'm very rusty, but I can
remember doing this sort of thing extensively a few years back.
stopping me from using something more up to date. Here's the problem I'm
having:
I'm updating data in a A97.mdb (lets say "archive.mdb") with info from a
..csv file, from code in another A97.mdb (lets say "control.mdb"). Control.mdb
has some static data tables in it. To do the transfer, I'm creating a temp
database in c:\temp, and linking the 3 parts of my data transfer to it as 3
linked tables - archive, source and, say, lookup. Now, I can do select and
delete queries on these tables just fine in DAO, and when I open this temp db
by hand I can do what I want to do by hand just fine using a query - insert
into archive select * from source where (condition on lookup). Doing this by
hand by means of a query is fine. Yet when I try to do the same thing using
DAO, it treats my query as a pass-thru query and wants a (ODBC)connection
string - I'm transferring data between 3 linked tables, so I can't see why it
is treating this as a pass-thru, when doing so manually appears to treat the
query as being an intra-database object.
I can code around this eg I can open the archive database and bring the data
into it directly, do my processing on it, and so on ... but I'd like to know
what is going on, and why it won't work doing it this way, in particular why
when I create queries by hand and by DAO there is the different treatment -
why the DAO ones are coerced into being pass-thrus. I'm very rusty, but I can
remember doing this sort of thing extensively a few years back.