SQL Server Global Variables
Is there a way of creating a global variable in sql server?
I need to shorten the length of my triggers. Many of my triggers first look
up data in a config table for particular requirements, if those requirements
are met then it would execute the trigger.
If i could use a global variable to store these config values i wouldnt have
to keep looking them up.
Thanks
Julis Max
[412 byte] By [
Julius Max] at [2007-11-9 21:10:18]

# 1 Re: SQL Server Global Variables
there is no such thing as custom global variable in TSQL. The best you can
do is store them in a table as you have or create a UDF that returns them
"hard-coded" if they are specific to a single app/database.
--
HTH,
David Satz
Principal Web Engineer
Hyperion Solutions
"Julius Max" <forbesMaxi67@jelonetjr.com> wrote in message
news:3d92bfc3$1@10.1.10.29...
>
> Is there a way of creating a global variable in sql server?
> I need to shorten the length of my triggers. Many of my triggers first
look
> up data in a config table for particular requirements, if those
requirements
> are met then it would execute the trigger.
> If i could use a global variable to store these config values i wouldnt
have
> to keep looking them up.
>
> Thanks
>
> Julis Max