This month's discount Comprehensive Database Performance Health Check · Testimonials
SQLAuthority with Pinal Dave
Home
  • Consulting
    • Health Check
  • Free Videos
  • All Articles
    • AI
    • SQL Performance
    • SQL Tips and Tricks
    • Interview Questions and Answers
    • SQL Puzzle
    • SQL Video
    • SQLAuthority News
    • Personal
  • Books
  • Consulting
SQL SERVER - Introduction and Example for DATEFORMAT Command

SQL SERVER – Introduction and Example for DATEFORMAT Command

September 28, 2007
Pinal Dave
SQL Tips and Tricks
SQL DateTime, SQL Scripts

I found DATEFORMAT in a Jr. DBA’s code. SET DATEFORMAT sets the order of month, day and year so SQL Server can read date strings in other formats.

Read More
A key that does not fit the padlock on a wooden crate marked BACKUP.

SQL SERVER – FIX : Error 3154: The backup set holds a backup of a database other than the existing database

September 27, 2007
Pinal Dave
SQL Tips and Tricks
SQL Backup and Restore, SQL Data Storage, SQL Error Messages, SQL Scripts

Error 3154 says the backup set holds a backup of a database other than the existing database. Use WITH REPLACE in RESTORE, or drop the old database first.

Read More
SQL SERVER - Effect of TRANSACTION on Local Variable - After ROLLBACK and After COMMIT

SQL SERVER – Effect of TRANSACTION on Local Variable – After ROLLBACK and After COMMIT

September 25, 2007
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Transactions

What is the effect of a TRANSACTION on local variable values after ROLLBACK and after COMMIT? A short example I wrote for a Jr. Developer shows the answer.

Read More
SQL SERVER - Stored Procedure to Know Database Access Permission to Current User

SQL SERVER – Stored Procedure to Know Database Access Permission to Current User

September 23, 2007
Pinal Dave
SQL Tips and Tricks
SQL Cursor, SQL Scripts, SQL Stored Procedure, Undocumented SQL

Which databases can I use? Run EXEC sp_MShasdbaccess to see the database access permission of the current user. Our Jr. DBAs check it all the time.

Read More
SQL SERVER - 2005 - Version Information and Additional Information - Extended Stored Procedure xp_msver

SQL SERVER – 2005 – Version Information and Additional Information – Extended Stored Procedure xp_msver

September 22, 2007
Pinal Dave
SQL Tips and Tricks
SQL Scripts

EXEC xp_msver returns SQL Server version information plus server details like platform, language and file version, with no need to check Windows system info.

Read More
SQL SERVER - 2005 - Multiple Language Support

SQL SERVER – 2005 – Multiple Language Support

September 21, 2007
Pinal Dave
SQL Tips and Tricks
SQL Scripts

Multiple language support in SQL Server: sys.syslanguages holds the details for each language, including month and day names. One query lists them all.

Read More
SQL SERVER - Rename Database to New Name Using Stored Procedure by Changing to Single User Mode

SQL SERVER – Rename Database to New Name Using Stored Procedure by Changing to Single User Mode

September 19, 2007
Pinal Dave
SQL Tips and Tricks
Database, SQL Scripts, SQL Stored Procedure

How we rename database copies on our development server: set it to single user mode, run sp_renamedb, then set it back. The file names do not change.

Read More
Previous 1 … 332 333 334 335 336 337 338 … 365 Next
  • Books
  • Testimonials
  • Privacy Policy

© 2006 – 2026 All rights reserved. pinal @ SQLAuthority.com