Wednesday, May 5, 2010

SQL Server built in functions

1. First day of the week
select @@DateFirst output: 7 - Monday , 1 - Sunday
Set dateFirst 1
To see the permissions in the database.
select * from fn_my_permissions('null','database')
SELECT DISTINCT class_desc FROM fn_builtin_permissions(default) ORDER BY class_desc;
GO

No comments: