Hi what is the difference between
set @flag=1 and set @@flag = 1 in SQL Server?
set @flag=1
set @@flag = 1
thanks
Nothing. Some built-in functions have names starting with double with the @@ signs as a legend. To avoid confusion, it is often recommended to use names starting with @@ .
@@
Source: MSDN: Using Identifiers β Rules for Regular Identifiers .