Hello,
Issue:
When a query is attached to a MS Access table the AutoNumber will show the new ID increment before the record is committed. When the underlying table is in MS SQL the increment does not appear until the record is committed.
This link has the best information I could find so far on auto incrementing columns.
https://docs.microsoft.com/en-us/dotnet/framework/data/adonet/retrieving-identity-or-autonumber-values
The solution provided by the MS link indicates I would need to have an adodb connection that pulls the next id using IDENT_CURRENT function.
The reason I am asking is because when new records are created I track the primary key / form name that created the record using the before update event. When the table is on SQL server the primary key is null in the audit table for new records.
Thanks,
Issue:
When a query is attached to a MS Access table the AutoNumber will show the new ID increment before the record is committed. When the underlying table is in MS SQL the increment does not appear until the record is committed.
This link has the best information I could find so far on auto incrementing columns.
https://docs.microsoft.com/en-us/dotnet/framework/data/adonet/retrieving-identity-or-autonumber-values
The solution provided by the MS link indicates I would need to have an adodb connection that pulls the next id using IDENT_CURRENT function.
The reason I am asking is because when new records are created I track the primary key / form name that created the record using the before update event. When the table is on SQL server the primary key is null in the audit table for new records.
Thanks,