Hi,
I tried using the query SELECT @@IDENTITY to retrieve the Identity value of
a record after inserting it in a Replicated Access 2000 database but it
always returned 0, the Primary Key field in my table is of type Guid (not
Autoincrement).

Does anyone has any suggestions as to how I can retrieve the Guid ID value
from the Inserted Record

Thank You,
Sameer

Re: Problem with SELECT @@IDENTITY query by Joe

Joe
Fri Dec 05 22:39:44 CST 2003

As I understand it your app should set the GUID and include it in the Insert
statement.
Then you do not even need to get it back.
That is the big advantage to a GUID - you already know it.
--
Joe Fallon



"Sameer Motwani" <smotwani@ac2.net> wrote in message
news:uH8avD5uDHA.1756@TK2MSFTNGP09.phx.gbl...
> Hi,
> I tried using the query SELECT @@IDENTITY to retrieve the Identity value
of
> a record after inserting it in a Replicated Access 2000 database but it
> always returned 0, the Primary Key field in my table is of type Guid (not
> Autoincrement).
>
> Does anyone has any suggestions as to how I can retrieve the Guid ID value
> from the Inserted Record
>
> Thank You,
> Sameer
>
>



Re: Problem with SELECT @@IDENTITY query by William

William
Sat Dec 06 13:07:35 CST 2003

Sammer:

I'm not sure about GUID columns, but you can use this
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconretrievingidentityorautonumbervalues.asp
to do it with a standard autoincrement field in access. .
"Sameer Motwani" <smotwani@ac2.net> wrote in message
news:uH8avD5uDHA.1756@TK2MSFTNGP09.phx.gbl...
> Hi,
> I tried using the query SELECT @@IDENTITY to retrieve the Identity value
of
> a record after inserting it in a Replicated Access 2000 database but it
> always returned 0, the Primary Key field in my table is of type Guid (not
> Autoincrement).
>
> Does anyone has any suggestions as to how I can retrieve the Guid ID value
> from the Inserted Record
>
> Thank You,
> Sameer
>
>