SQL Server Interview Questions and Answers - (31-40)
SQL Server Interview Questions and Answers - (31-40)
31. Can we create multiple listeners for the single Always On Availability Group?
a. Yes
b. No
32. From which SQL Server version the database level health detection is available in
Always On?
a. 2014
b. 2016
c. 2017
d. 2019
33. Which permission is needed to create a Publication in SQL Server Replication?
a. Db_Datawriter
b. Security Admin
c. Process Admin
d. Db_Owner
34. Can we configure SQL Server Replication for the database which is part of
Availability Group?
a. Yes
b. No
35. To configure Snapshot replication a table must contain a primary key. True or
false?
a. True
b. False
36. Can we put the database in read_only mode when it is offline?
a. Yes
b. No
37. To Configure SQL Server Database mirroring the partner and the Witness must
be running on the same edition. True or false?
a. True
b. False
38. We can configure Database mirroring for the database which is in Bulk-logged
recovery model. True or false?
a. True
b. False
39. A mirrored database can be renamed during a database mirroring session. True
or false?
a. True
b. False
40. We can't configure both log shipping and database mirroring on the same
database. True or false?
a. True
b. False
Answers
31. Can we create multiple listeners for the single Always On Availability Group?
a. Yes
b. No
A. We can create multiple listeners for Single AG Group but we can able to configure one listener
though Management Studio.
If you want to configure additional listener you have to do it using failover cluster
manager.
You will be getting the below error if you are trying to configure other than one listener
through Management studio
But still you can add another listener using failover cluster manager
You can click on Add resource and select Client Access Point
Provide a unique listener name
--Source: learn.microsoft.com
34. Can we configure SQL Server Replication for the database which is part of
Availability Group?
a. Yes
b. No
A. Yes, we can configure replication and always on the same database but we have some
limitations.
In an AlwaysOn availability group a secondary database cannot be a publisher.
35. To configure Snapshot replication a table must contain a primary key. True or
false?
a. True
b. False
A. To configure Snapshot replication it’s not a mandatory to have a primary key for the
table.
When we use snapshot replication:
--Source: learn.microsoft.com
36. Can we put the database in read_only mode when it is offline?
a. Yes
b. No
A. Yes, you can put the database in read_only mode when it is in offline state, but not in
GUI, we have to run the below script.
USE [master]
GO
ALTER DATABASE [Test] SET READ_ONLY WITH NO_WAIT
GO
You can’t put the database in read_only mode in GUI, you can’t see the properties
of a database
37. To Configure SQL Server Database mirroring the partner and the Witness must
be running on the same edition. True or false?
a. True
b. False
A. To configure Database mirroring both Principle and Mirror server editions should be
same but Witness must not be the same edition.
Witness server can run on any edition of SQL Server that supports database
mirroring.
38. We can configure Database mirroring for the database which is in Bulk-logged
recovery model. True or false?
a. True
b. False
A. The database must be in Full recovery model and we can not include system
databases in mirroring.
39. A mirrored database can be renamed during a database mirroring session. True
or false?
a. True
b. False
A. A mirrored database can not be renamed during a database mirroring session.
40. We can't configure both log shipping and database mirroring on the same
database. True or false?
a. True
b. False
A. Yes, we can configure log shipping and mirroring on the same database but there are
some limitations.