Hi all,
This is just beyond my reach brain-wise, any assistance greatly appreciated.
BACKGROUND:
Front End MS Access 2003, Back End MySQL.
Pass-through query (QryA) references all data in remote table (TblA).
Local Table (TblB) is created from QryA based upon user-specified criteria. The primary key in QryA (pkey) is included as a criterion.
ISSUE:
Users will update data in TblB via FormA. Once data is updated I want to run an query to update corresponding records in the remote table HOWEVER I do not want to link the remote tables. This is because MS Access insists on loading the entire dataset of a linked table into memory on load/upon linking.
I have successfully utilised the method in this article to compile update strings for individual records with information contained in a form but can't determine how to adapt it to use a local table as the source to update multiple records. The issue appears to be that the ODBC call is trying to locate the local table name on the remote server, thus returning a 'call failed' error. SQL as follows:
I want to avoid having to iterate through and create a new pass-through update query for each individual record in TblB. Can anyone offer a solution to update a remote table with information contained in a local table using a pass-through query and without having to link the remote table?
Cheers
This is just beyond my reach brain-wise, any assistance greatly appreciated.
BACKGROUND:
Front End MS Access 2003, Back End MySQL.
Pass-through query (QryA) references all data in remote table (TblA).
Local Table (TblB) is created from QryA based upon user-specified criteria. The primary key in QryA (pkey) is included as a criterion.
ISSUE:
Users will update data in TblB via FormA. Once data is updated I want to run an query to update corresponding records in the remote table HOWEVER I do not want to link the remote tables. This is because MS Access insists on loading the entire dataset of a linked table into memory on load/upon linking.
I have successfully utilised the method in this article to compile update strings for individual records with information contained in a form but can't determine how to adapt it to use a local table as the source to update multiple records. The issue appears to be that the ODBC call is trying to locate the local table name on the remote server, thus returning a 'call failed' error. SQL as follows:
Code:
UPDATE TblB INNER JOIN TblA ON (TblB.ID = TblA.pkey)
SET TblA.completiondate = TblB.completiondate, TblA.m1 = TblB.m1, TblA.m2 = TblB.m2, TblA.m3 = TblB.m3, TblA.m4 = TblB.m4, TblA.m5 = TblB.m5, TblA.m6 = TblB.m6, TblA.pnotes = TblB.pnotes, TblA.rating = TblB.rating, TblA.rnotes = TblB.rnotes, TblA.kpi = TblB.kpi;
I want to avoid having to iterate through and create a new pass-through update query for each individual record in TblB. Can anyone offer a solution to update a remote table with information contained in a local table using a pass-through query and without having to link the remote table?
Cheers