|
|
-
|
|
In Management Studio 2008 R2, restore database dialog is as below:
Management Studio 2008 R2
You need to select the backups which you need to restore from the backup set list.
This dialog box is tweaked in "Denali":
Management Studio "Denali"
First, thi......
|
|
-
|
|
These are new functions in SQL Server "Denali". DATEFROMPARTS() returns a DATE value with specified day, month and year.
It takes three arguments:
DATEFROMPARTS (@Year, @Month, @Day)
If the arguments are invalid, it raises an error.
– © 2011 – Vishal (http://SqlAndMe.com)
SE......
|
|
-
|
|
Yesterday, I posted about
SQL Server – Management Studio – Schema Changes History Report and Default
Trace and their limitations. It does not capture the details of modification. i.e.
When a new column is added to a table, you can find out when the changes to th......
|
|
-
|
|
Schema Changes History Report produces the list of changes done using DDL. It pulls this information from the Default Trace.
You can access the report from Management Studio:
1. Right Click on Database, for which you want to view the report,
2. Go to Reports > Standard Reports > Schema Changes Hi......
|
|
-
|
|
Since SQL Server 2005 we have LOGON Triggers, these are DDL Triggers which are created
at Server level. These triggers are created to respond to a Login Event. LOGON Trigger
executes after the Authentication has been made successfully.
LOGON Triggers can be useful in may ways,......
|
|
-
|
|
By using GROUPING SETS() we can specify multiple groupings in a single query.
GROUPING SETS() generates the result by producing a UNION ALL set
of the result sets generated by specified grouping sets.
for example, consider below data:
-- © 2011 – Vishal (http://Sql......
|
|
-
|
|
SQL Server Login Auditing can be used to monitor login activities on SQL Server Database Engine. SQL Server can log both failed and successful login attempts on the server. It provides four different options for Login Auditing.
1. None – No Login activity is logged,
2. Failed logins only &nd......
|
|
-
|
|
CUBE() produces the result set by generating all combinations of columns specified in GROUP BY CUBE(). As with GROUP BY ROLLUP() it adds sub-total and grand-total rows as well.
For example, consider below data:
-- © 2011 – Vishal (http://SqlAndMe.com)
SELECT [Group], [Name], [S......
|
|
-
|
|
GROUP BY groups the result set into summary rows by provided columns. For example, consider below data which contains sales figures by region.
Group Name SalesYTD
—————— ——————- ......
|
|