|
System functions provide information at a system level.
The following examples show how to obtain the name of the current user and database:
If you want to obtain this information for every record in a table, use the following (the example uses the Person table in DEMODATA):
The following example creates a column of data type UNIQUEIDENTIFIER as the first column in new table "table1." Setting a default value with the NEWID function provides a unique value for "col1" in each new row within the table.
|
Chapter contents
Prev topic: Time and Date Functions
|