troubleshooting Question

how so I get the uniqueidentifier after insert in SQLEXPRESS?

Avatar of Agent909
Agent909 asked on
Visual Basic.NETMicrosoft Development
2 Comments1 Solution398 ViewsLast Modified:
I need to create a batch number for entering a set of records.  I have a batch table that stores the unique batch number and other information about the batch.  When the user clicks "New" to create a new batch, I use the Insert command to add the record.  But then I need the uniqueidentifier that was created for the batch number.  What is the SQL syntax for this?

Thanks in advance!
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 2 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros