I have a query that instert a record into a table. Th record has an identity field,id.
As soon as the record has been inserted I need to know the id value some relational purposes.
I can use the max function, but since records will be inserted to by many users I need to make sure that the id I get is the one corresponding to the record inserted, with no cnfusion between 2 records inserted almost simultaneoulsy.
I would like to insert and have sql return unambigously the id of the insterted record.