SQL Server tutorial

          

SQL Server Tutorial

SQL Server Topics  
SQL Server interview Sql Server database maintenance
SQL Server backup SQL Server cursor
SQL Server replication Structured query language
SQL Server architecture SQL Server constraints
SQL Server cursors Data mining
Data warehousing SQL Server DTS
SQL Server functions SQL Server indexes
SQL Server joins SQL Server locks
SQL Server net integration SQL Server optimization
SQL Server replication SQL reporting services
SQL service broker SQL Server stored procedures
SQL Server table SQL Server transactions
SQL Server transactions architecture SQL Server triggers
SQL Server views SQL Server XML integration
SQL Server DDL SQL Server DML
SQL Server DCL SQL Server identifier
SQL Server data integrity SQL Server accessing data
SQL Server subqueries SQL Server cube operator
SQL Server insert data SQL Server distributed queries
SQL Server index tuning  
 

Explain the concepts and capabilities of query parallelism.

Latest answer: Parallelism is the process of executing queries in parallel to increase performance...........

What is the difference between a table and index scan in an execution plan?

Latest answer: When a query needs to be optimized, an execution plan is created by the query optimizer........

Describe why it takes so long to drop a clustered index.

Latest answer: A clustered index is uses the index key to sort the data of the table. And since there can be only one sort order, there can be only one clustered index.........

Describe what happens when SQL Server executes a stored procedure or query.

Latest answer: When the SQL server needs to execute a query, it makes use of the execution plan available in the memory. If not, the query is compiled in 4 stages...........

Explain a variety of tips that can help speed up INSERTs.

Latest answer: Ensure the server has enough memory, Less number of indexes on a table.........

Explain the significance of WITH RECOMPILE option when creating a stored procedure.

Latest answer: When a stored procedure is created using WITH RECOMPILE option, the execution plan for the procedure is not cached...........

Explain the difference between RECOMPILE query hint and WITH RECOMPILE option.

Latest answer: When a stored procedure is created using WITH RECOMPILE option, the execution plan for the procedure is not reused............

What is page splits? How many page splits is too many? What can I do to help reduce them?

Latest answer: Page splits are performed when there is no space in a data page to accommodate more inserts or updates. In a page spilt, SQL server removes some data from the current data page and moves it to another data page..........

Explain the ways to capture Performance Monitor data for review purpose.

Latest answer: One of the cheapest ways to capture performance monitor data is to use performance monitor itself. The performance monitor can be used to create logs of each activity..........

tempdb database grows so large that it runs out of disk space. What causes this and how can I prevent it?

Latest answer: Most of the times the query design is responsible for increase in size of tempdb database. The query returns a large amount of rows when no predicate or where clause is specified............

Explain the concepts and capabilities of partitioned views.

Latest answer: Partitioned view joins the horizontally portioned data. This data may belong to one ore more servers. It makes the data appear as one table.............

How do you restore the master database on a SQL Server cluster?

Latest answer: Restoring a master database on a SQL server cluster is required in case of a disaster when the previous backup is required.............

Explain some guidelines for estimating the space needed for a database.

Latest answer: Estimating the space needed for a database is essential to figure out the performance of the application and size of database.............

Does a SQL Server cluster support load balancing? Explain

Latest answer: SQL server cluster does not support load balancing.............

How many indexes in a table you can have depends on many factors. Explain those factors.

Latest answer: As the data in a table is modified, each index on the table needs to be updated. This is certainly an overhead. If the data modification queries are slowing down, it means that more indexes are used in the table...........

T-SQL code in script run faster than it does as a stored procedure. Why?

Latest answer: This usually happens when index statistics are not up-to-date. They can be by reindexing them and using "Auto Create Statistics" and "Auto Update Statistics" options from database settings.............

Explain the implications of server clustering on replication.

Latest answer: Server clustering on replication involves many manual and tedious tasks...........

How can you use IIf in Transact-SQL?

Latest answer: IIf is most commonly used in Microsoft access to determine if another expression is true or false............

What happens when my integer IDENTITY runs out of scope?

Latest answer: An integer data type can have a variety of IDENTITY values like int, bigint, tinyint etc.............

What is the purpose of SYSMON/PERFMON utility?

Latest answer: SYSMON/PERFMON utility provides system resources usage details...........

How to send a SSRS report from SSIS?

Latest answer: SSIS has the ability to send SSRS report in different formats like Excel, PDF etc...........

How to alter a User Defined Data Type?

Latest answer: The only way to alter a User Defined Data Type is to drop the existing and create a new one............

How do you create trigger on system tables? What can be the reasons to create trigger on system tables?

Latest answer: Even though creating triggers on system tables should be avoided, following are the probable reasons why one would want to create triggers on system tables.........

How to integrate Performance Monitor and SQL Profiler.

Latest answer: In order to Integrate Performance Monitor and SQL Profiler, server performance needs to be captured simultaneously using both Performance Monitor’s Counter Logs and SQL Server Profiler.................

How to schedule SSAS Database backup.

Latest answer: SSAS database backups can be taken using SQL Server Management Studio (SSMS). In order to create a backup using the SSAS backup option, a SQL Server Agent Job needs to be created and scheduled................

How to Generate an Auto Incremental Number in a SSIS Package?

Latest answer: Auto incremental numbers in a SSIS package can be provided using script components.............

Difference between ORDER BY and the COMPUTE BY lists.

Latest answer: COMPUTE BY is used to generate sub totals or summary of a result set. They are used with an ORDER BY clause............

Explain the purpose of KILL command. Provide an example.

Latest answer: A KILL command in SQL is used to end or KILL a sql server process that is identified using a system process id............

What are the pros and cons of running more than one instance of SQL Server on a single physical server?

Latest answer: Having multiple instances allows SQL server to have multiple instances that can be helpful in development and testing environment.........

Explain how to disable database mirroring for a particular database.

Latest answer: Mirroring helps to increase database availability. In situations where mirroring needs to be disabled, ENDPOINT of the database should be deleted.........

Explain the new data types introduced in SQL SERVER 2008.

Latest answer: New date and time data types considering time zones as below..........

Explain how to rebuild Master Database.

Latest answer: The Master database can be rebuilt using the following steps:.........

What is LINQ? Explain its features

Latest answer: Language Integrated Query allows different features to be integrated in the basic programming language used in an application............

What is Catalog Views? Its purposes

Latest answer: Catalog views can be used to return information like objects, logins permissions etc used by SQL server database engine............

What is PIVOT and UNPIVOT?

Latest answer: PIVOT is a relational operator used to provide a more readable or simpler view of a table’s data............

What is SQLCMD?

Latest answer: SQLCMD is a command line utility that is used to run queries from the command prompt..........

What do you mean by Table Sample?

Latest answer: TABLESAMPLE is a clause that can be used in a FROM clause query to limit the number of rows retuned from a result set..........

What is use of EXCEPT Clause? Explain with an example

Latest answer: EXCEPT clause is used to return records that are returned by the first query and NOT the second query............

Explain the use of NOLOCK query optimizer hint.

Latest answer: NOLOCK table hint used using WITH clause, is similar to read uncommitted. This option allows dirty reads are allowed............

In SQL SERVE 2008 Data Compression comes in two flavors: Row Compression, Page Compression. Explain them

Latest answer: SQL allocates 4 bytes for an integer data type irrespective whether the number is small or large............

How to copy the tables, schema and views from one SQL Server to another?

Latest answer: The database can be detached from one server and attached to another. Methods are : sp_detach_db and sp_attach_db..........

How to copy data from one table to another table?

Latest answer: Data from one table can be copied into another using the INSERT INTO clause..............

What is CTE? Advantages

Latest answer: CTE is Common Table Expression. It is a temporary result set for an INSERT, UPDATE or a SELECT query............

How to find tables without Indexes?

Latest answer: Tables without indexes can be found using the OBJECTPROPERTY method............

What is the effect of DBCC CHECKDB and DBCC DBREINDEX on the Transaction log?

Latest answer: DBCC DBREINDEX is an offline operation is used to rebuild the indexes of a table dynamically...........

What is the purpose of the Surface Area Configuration Tool in SQL Server 2005?

Latest answer: The SQL Server 2005 Surface Area Configuration Tool helps in turning ON features that are turned OFF by default...........

How can I disable or rename SA account in SQL Server 2005?

Latest answer: SA account in SQL server can be renamed or disabled using ALTER LOGIN command............

What is the usage of the WITNESS instance in SQL Server 2005 Database Mirroring?

Latest answer: The WITNESS server is used to enable the mirror server to recognize the necessity of failover.............

What are ways that can be used to avoid using cursors in my applications?

Latest answer: The cursor can be written as a normal query in case of scenarios when the task needs to be performed repeatedly.............

In Reporting Services there is a global parameter called ReportServerUrl. Explain its purpose

Latest answer: ReportServerURL is used to set or get URL for the report server. Jscript uses get ReportServerUrl(uri value) and post ReportServerUrl(uri value)...........

In Performance Monitor, there is an object called Network Interface. What does it mean and under what circumstances would you use it?

Latest answer: Network interface is used to monitor activities of the network cards present on the server...........

Lookup's are a key component in SQL Server Integration Services (SSIS). Explain its purpose

Latest answer: Lookup transformation combines data from two sources. The fields of these sources are matched.........

How to unzip a File in SSIS?

Latest answer: Execute Process Task in the Control Flow task can be used to unzip a file............

SQL Server's performance can be affected by using NULLS in your database. Explain how.

Latest answer: NULL values in the database for a column particularly cause problems in searching and comparison.............

Since functions are not pre-compiled, is there any performance gain from using user-defined functions as opposed to stored procedures?

Latest answer: Stored procedure performs better in comparison to user defined functions. Stored procedures are precompiled and executed on the database server.............

What are the ways to identify the worst performing queries in my SQL Server database application?

Latest answer: Worst performing queries in my SQL Server database application can be identified using Dynamic Management views and Dynamic Management Functions. It helps to find the internal working of SQL instances and database objects..............

What is the difference between UNION and UNION ALL?

Latest answer: UNION command selects distinct and related information from two tables. On the other hand.............

What is use of DBCC Commands?

Latest answer: Database Consistency Checker Commands give details in form of statistics about the SQL Server..............

What is Log Shipping?

Latest answer: UNION command selects distinct and related information from two tables. On the other hand.............

What is the difference between a Local and a Global temporary table?

Latest answer: A local temporary table lives until the connection is valid or until the duration of a compound statement..............

What is the STUFF and how does it differ from the REPLACE function?

Latest answer: STUFF function is used to insert a string into another string by deleting some characters specified.............

How to transfer or export SQL Server 2005 data to Excel

This chapter excerpt is from Beginners Guide to SQL Server Integration Services Using Visual Studio 2005 by Jayaram Krishnaswamy, is printed with permission from Packt Publishing, Copyright 2007.


How to transfer or export SQL Server 2005 data to Excel
SQL Server Interview questions
Interview Questions on SQL Server Replication
Interview Questions on SQL Server Cursor
Sql Server DBA interview

What are the steps to take to improve performance of a poor performing query?
What is a deadlock and what is a live lock? How will you go about resolving deadlocks?
What is blocking and how would you troubleshoot it?.............

Sql Server database maintenance

Explain the concepts of faster differential backups.
Explain the concepts of Parallel Database consistency check (DBCC)
Define Indexed view.
Define Distributed partitioned views.

SQL Server backup devices and methods

Database backup methods - Full Backups, Differential Backups, Transaction Log Architecture Backups, File and Filegroup Backups.

What is RAID (Redundant Array of Inexpensive disks)? Explain its level.

RAID is a mechanism of storing the same data in different locations. Since the same data is stored, it is termed as redundant............

SQL Server 2005 XML support

Explain the concepts and capabilities of SOAP. Explain the purpose of Native XML mode in SQL Server 2005.
Native XML Access vs. SQLXML.
Benefits of Native XML Access in SQL Server 2005.
Limitation for Native XML Web Services.

Transferring a View from Oracle 10G XE to an SQL Server 2005 Database

Here you will learn how to copy a table on an Oracle 10G XE database to a database on the SQL Server 2005. You will also learn how to install an Oracle 10G XE server and work with its database objects.



Write your comment - Share Knowledge and Experience


 

Latest MCQs
» General awareness - Banking » ASP.NET » PL/SQL » Mechanical Engineering
» IAS Prelims GS » Java » Programming Language » Electrical Engineering
» English » C++ » Software Engineering » Electronic Engineering
» Quantitative Aptitude » Oracle » English » Finance
Home | About us | Sitemap | Contact us | We are hiring