[AccessD] Return Autonumber Value

paul.hartland at fsmail.net paul.hartland at fsmail.net
Fri Jan 12 04:54:45 CST 2007


To all,

I have a user log table (tblUserLog) for which I want to store user logon details (Name, LogonDate, LogonTime, LogoffTime, TotalTime), I also have an autonumber field called LogID.  What I need is when I write the initial user log details, I want to return the LogID into a variable.  What I did think of is write the record details and then do a MAX on the LogID field, but what would happen if two users logged on at the same time would it be possible to return the wrong LogID for one of the users ?

What is the best way to go about this ?

Thanks in advance for any help.

Paul Hartland


More information about the AccessD mailing list