# vs ## Table

#temp tables are available ONLY to the session that created it and are dropped when the session is closed. ##temp tables (global) are available to ALL sessions, but are still dropped when the session that created it is closed and all other references to them are closed. Local temporary tables are visible only in the... » read more

SQL Bitwise Operators

Bitwise Operators X Y X&Y X|Y X^Y ~X 0 0 0 0 0 1 0 1 0 1 1 1 1 0 0 1 1 0 1 1 1 1 0 0 See the following topics: & (Bitwise AND) &= (Bitwise AND Assignment) | (Bitwise OR) |= (Bitwise OR Assignment) ^ (Bitwise Exclusive OR) ^=... » read more

Creating Unique Constraints

Unique constraint on a column to prevent duplicate entry on a column. Using SQL Server Management Studio In Object Explorer, right-click the table to which you want to add a unique constraint, and click Design. On the Table Designer menu, click Indexes/Keys. In the Indexes/Keys dialog box, click Add. In the grid under General, click Type and choose Unique Key from the drop-down list box to the right... » read more