Win 7 32 bit, Access 2003
I have created a number of temporary tables at run time, they are unique to a user for the current session. The tables are created by a template of the table with the created table name containing the sign on name of the user, this produces unique table names. The problem I am having is that when I do an INSERT or UPDATE to one of the temporary tables that action is replicated in the template and all the created tables. e.g if I have
template table = tblTemplateDisplay
created tables tblTemplateDisplayJack and tblTemplateDisplayMary
then when I INSERT a row in tblTemplateJack it is also inserted into tblTemplateDisplay and tblTemplateDisplayMary.
The code to create the tables is:
Any insights will be appreciated.
tia Jack
I have created a number of temporary tables at run time, they are unique to a user for the current session. The tables are created by a template of the table with the created table name containing the sign on name of the user, this produces unique table names. The problem I am having is that when I do an INSERT or UPDATE to one of the temporary tables that action is replicated in the template and all the created tables. e.g if I have
template table = tblTemplateDisplay
created tables tblTemplateDisplayJack and tblTemplateDisplayMary
then when I INSERT a row in tblTemplateJack it is also inserted into tblTemplateDisplay and tblTemplateDisplayMary.
The code to create the tables is:
Code:
' drop and create a new temporary
' the drop is to take into account any changes to the master template of the table
DoCmd.SetWarnings False
If utfnTableExists(gstrTempActiveSharesTableName) = True Then
strQuery = "DROP TABLE " & gstrTempActiveSharesTableName
DoCmd.RunSQL strQuery
End If
' now create temporary tables for this session, this user
DoCmd.CopyObject , gstrTempActiveSharesTableName, acTable, gcstrTemplateActiveSharesTableName
tia Jack