Home>SQL Server (Page 9)

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 ‘SmarterTrack’ Run Multiple SQL Files …

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 code 0x8009030c while establishing a …