Month: September 2014

Common SQL Tasks I Do and Scripts

Common SQL Tasks I Do and Scripts  Restore a database from Backup : RESTORE FILELISTONLY FROM DISK = ‘\\FileShare\Database\Database.bak’ RESTORE DATABASE SmarterTrack FROM DISK = ‘\\FileShare\Database\Database.bak’ WITH REPLACE , MOVE ‘SmarterTrackModel’ TO ‘G:\SQLServer\MSSQL10_50.DEV2008R2\MSSQL\DATA\SmarterTrack.mdf’ , MOVE ‘SmarterTrackModel_log’ TO ‘G:\SQLServer\MSSQL10_50.DEV2008R2\MSSQL\DATA\SmarterTrack_log.ldf’ EXEC sp_helpdb

Common SQL Errors and Solutions

Error : Msg 7411, Level 16, State 1, Line 1 Server ‘DEVSQLDEV2008’ is not configured for RPC. Solution : exec sp_serveroption @server=’DEVSQLDEV2008′, @optname=’rpc’, @optvalue=’true’ exec sp_serveroption @server=’DEVSQLDEV2008′, @optname=’rpc out’, @optvalue=’true’ Error : 2014-09-11 16:14:23.410 Logon SSPI handshake failed with error

Measure T-SQL / Stored Procedure Performance

Measure T-SQL / Stored Procedure Performance If you are using SQL Server or dealt with SQL Server in any fashion, you might have heard this million times, How do you measure the TSQL ( Adhoc ) or Stored Procedure  Performance. I

SQL Server – Orphaned Users

SQL Server – Orphaned Users A database user for which the corresponding SQL Server login is undefined or is incorrectly defined on a server instance cannot log in to the instance. Such a user is said to be an orphaned

Top