GUID is not an identity field

  • Thread starter Thread starter Jason L James
  • Start date Start date
J

Jason L James

Hi all,

I am using merge replication between my SQL 2K and CE
databases.

I am using GUID types as the PK of my data table. However,
I would like to return the value of the PK once the record has
been written. I am using newID() in the SQL CE DB so the DB
is adding the GUID value. Therefore I can not use

SELECT @@IDENTITY

does anyonce have any ideas how I can return the PK
of the most recently added record?

Thanks,

Jason.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top