Category Archives: SQL

Microsoft SQL Server

The difference between REVOKE and DENY

If I GRANT SELECT (or UPDATE/INSERT/DELETE) permissions to a user, then they can use those permissions to view data in a table. If I REVOKE the permissions, it’s the same as if the user never had them. They would need … Continue reading

Posted in SQL | Leave a comment

Finding all Columns of an Index

Copy and paste the script in a database to analize, then replace de variable @tblName with the table name to analize and execute /************ Identify all columns of all indexes on a table***********/ DECLARE @tblName AS sysname select @tblName =’TABLE_NAME’ … Continue reading

Posted in SQL | Tagged , , | Leave a comment

Date and Time Functions in SQL Server 2008

Higher-Precision System Date and Time Functions  SYSDATETIME Returns a datetime2(7) value that contains the date and time of the computer on which the instance of SQL Server is running. The time zone offset is not included. Example: 2011-07-26 23:48:50.2038641 SYSDATETIMEOFFSET … Continue reading

Posted in SQL | Tagged , , , , , , , , , , , , , , , , , , | Leave a comment

SQL Server 2008 New DATETIME DataTypes

This article is going to cover the newly introduced data types in SQL Server 2008. The DATETIME function’s major change in SQL Server 2008 is the four DATETIME data types introduced. They are DATE, TIME, DATETIME2 and DATETIMEOFFSET. DATE Data Type … Continue reading

Posted in SQL | Tagged , , , | Leave a comment

SQL Server “Denali”: New Certifications

The Microsoft certifications for the next version of SQL Server, there will be seven exams: Four certification exams are planned for SQL Server “Denali” Business Intelligence roles: Writing queries with Transact-SQL (T-SQL) ETL Developer or Data Warehouse Developer. People in this role cleanse … Continue reading

Posted in SQL | Tagged , , , , , , , , , , , | Leave a comment