SQL Server – Database Mirroring for Disaster-Recovery Solution

What is Database Mirroring? Database mirroring is a solution for increasing the availability of a SQL Server database. But it has been gained popularity as a disaster-recovery option. How Database Mirroring Working. The principle server sends the active transaction log record to the mirrored server. The mirrored server applies the

» Read more

SQL Server – Understanding of SQL Server Role and Database Role

SQL Server supports the two authentication mode as Windows authentication mode and Mixed authentication mode. Once the user is authenticated, SQL server will allow access to the user based on the permission that user has. All the user permissions are based on Server Role and Database Role. So let try

» Read more

SQL Server 2012 – Get Backup History of the database

The msdb database is system database used by SQL Server Agent for scheduling alerts and jobs. msdb.dbo.backupset – Contain the information concerning the most-granular details of the backup process msdb.dbo.backupmediafamily – Contains the metadata for the physical backup files as they relate to backup sets Using the above mentioned tables,

» Read more

Schedule Automatic Backup in SQL Server 2012 – Part2

In the previous post, we have scheduled automatic backup in SQL Server 2012 – Part1. As we have scheduled daily backup of database and backup file will be generated every day. It is a good practice that to delete backup files after a certain period of time as per requirement.

» Read more

SQL Server – Authentication Mode – Windows Mode and Mixed Mode

During the installation of SQL Server you can choose the authentication mode for Database Instance. SQL Server support the two authentication mode as Windows authentication mode: Windows Authentication mode enables Windows Authentication and disables SQL Server Authentication.  Even if you choose Windows Authentication mode during SQL Server installation “sa” user

» Read more

SQL Server – How to add column dynamically in where clause

In this post, we will learn with example how to add the column dynamically in where clause. Example: For demo we have table as shown in the snapshot Basically we want to execute following script (i.e. Script: 1) but column name (i.e. FIRST_NAME) added dynamically in where clause. Script: 1

» Read more

SQL Server – The multi-part identifier could not be bound State – Msg 4104 – Fix

Error Msg Server: Msg 4104, Level 16, State 1, Line 1 The multi-part identifier could not be bound. Cause of this Error Msg: Case: 1 This error usually occurs when an alias is used when referencing a column in a SELECT statement and the alias used is not defined anywhere

» Read more
1 2 3 4 10