I need to to modify a stored procedure so that it can
determine if it is already running. I could create a
table to add/opdate a status record, but I would prefer
to read a system table looking for the proc running on
a connection if possible.
If anyone has done something like this, I would really
like to hear about it.
tia,
BillYou can't do that directly, but you can use an application lock inside your
stored procedure. See sp_getapplock in Books Online for the details.
Jacco Schalkwijk
SQL Server MVP
<bill_sheets@.hotmail.com> wrote in message
news:1107442939.517642.53580@.g14g2000cwa.googlegroups.com...
>I need to to modify a stored procedure so that it can
> determine if it is already running. I could create a
> table to add/opdate a status record, but I would prefer
> to read a system table looking for the proc running on
> a connection if possible.
> If anyone has done something like this, I would really
> like to hear about it.
> tia,
> Bill
>
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment