I cannot find any information that states whether the IDENTITY_VAL_LOCAL function retrieves the latest ID at a table level or at a Unit Of Work level.
This would be done directly after the insert to the parent table to enable the ID to be used as part of a concatenated key in another table.
My worry is that if multiple processes are inserting into the parent table will the correct ID be retrieved by the IDENTITY_VAL_LOCAL function or will it just get the latest ID inserted on to the parent table.
This would be done directly after the insert to the parent table to enable the ID to be used as part of a concatenated key in another table.
My worry is that if multiple processes are inserting into the parent table will the correct ID be retrieved by the IDENTITY_VAL_LOCAL function or will it just get the latest ID inserted on to the parent table.