[thelist] DB increments without an auto increment
rudy
r937 at interlog.com
Tue Apr 9 10:50:00 CDT 2002
> We're using MS SQL Server 7 as the database.
i'd better reply quickly before scott or anthony can jump in with their
suggestion that you use a stored procedure
you should use a stored procedure
one call to the database, voila, c'est fini
temp tables, locking, whatever you want
even a loop, it's like so cool to do that in a stored proc
but temp tables may make looping unnecessary
if you can seed an identity field in a temp table in a stored proc (never
tried this myself) with an initial value obtained using select max(id),
with a transaction block around it all...
... then you're golden
> Because we have no in-house experience writing desktop application
> we are writing these add-ons as intranet functions using ASP.
i know what you mean, but surely management can see the advantage of doing
it that way anyway -- i mean with intranet instead of client/server, not
with stored procs (you should use stored procs if possible in either case)
rudy
More information about the thelist
mailing list