>Ben,
>
>This is exactly the way we do the same thing (although, in our case, it's all done in Stored Procs, but the end result is the same).
>
>From BOL, here's the "definition" of SCOPE_IDENTITY():
>
>"Returns the last IDENTITY value inserted into an IDENTITY column in the same scope. A scope is a module -- a stored procedure, trigger, function, or batch. Thus, two statements are in the same scope if they are in the same stored procedure, function, or batch."
>
>So, it'll work just fine.
>
>~~Bonnie
Thank you soooo much. You just totally alleviated my fears. :-) Good to know I was on the right track. Thanks again!
________________________
Ben Santiago, MCP & A+
Programmer Analyst (SQL, FoxPro, VB, VB.Net, Java, HTML, ASP, JSP, VBS)
Eastern Suffolk BOCES - Student Data Services
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.
-Rich Cook