The following is the list of my articles published on SSWUG.org from March 2014 to July 2014. To read these articles, you must have SSWUG.org standard-level membership.
SQL Server 2014 Replication, Published on July 29, 2014
You use replication to move data between servers. Replication is important in distributed… Read more
I am very happy to announce that my first book “SQL Server 2014 Development Essentials” has now been published by Packt Publishing.
SQL Server 2014 Development Essentials is an easy-to-follow yet comprehensive guide that is full of hands-on examples, which… Read more
Implementing Checkpoints – To restart SQL Server Integration Services packages from the point of failure
An SQL Server Integration Services package often includes tasks that can take a long time to run. If the package fails in the middle of execution, you may need to repeat these tasks, which can be very slow and time-consuming. To address this problem, Integration Services supports the use of… Read more
You can use an HTTP endpoint to allow access to data over HTTP and Secure Sockets Layer (HTTPS) without needing to install Internet Information Services (IIS).
Important Note: HTTP Endpoints feature has been deprecate in SQL Server 2012 and later versions. For more information, see here
You use a join to combine data from different tables into a single result set. Joins most commonly use foreign key relationships. Some important points about joins include:
- Joins are created through instructions in the SELECT clause.
- Joins connect two or more tables by using a join operator.
- Joins exist…
In this article, you will learn about database design concepts. The database design concepts discussed in this article focus almost exclusively on OLTP requirements. OLAP design is beyond the scope of this article.
This article is published on SSWUG.org.
As part of the planning and research before implementing new SQL Server, you must determine the amount of space needed for your database and how it should be organized in the SQL Server. You also need to understand the properties of the database and how to manage the growth of… Read more
You can send e-mail from within stored procedures, functions, and triggers by using SQL Server Database Mail. You can also configure SQL Server Agent Mail to use Database Mail. Some features of Database Mail include:
- Uses Simple Mail Transport Protocol (SMTP)
- Does not require Outlook or Extended Messaging Application Programming…
Management tools play a vital role in enterprise database management. This is because the well-integrated tools extend the administrator’s capabilities, whereas a random collection of tools can lead to confusion, operational mistakes, high training costs, and poor DBA productivity. To keep up with these demands of complex enterprise database management… Read more
You are trying to drop a database user, but are getting the following error message:
The database principal owns a schema in the database, and cannot be dropped. (Microsoft SQL Server, Error: 15138)
This error is self-explanatory as it tells you that the database user you are trying to… Read more
I writing this blog post as a result of the following two questions, which I’ve been asked by one of my blog follower recently.
- Question#1: Does it matter who is the owner of the SQL Server Agent job?
- Question#2: Is there a way to quickly update the job owner for…
Availability databases in unhealthy data synchronization state (Error: 35285, Severity: 16, State: 1.)
After power surge last night, I realized few availability databases (also known as a “database replica”) have an unhealthy data synchronization state. What I mean from unhealthy is that they have a status of “Not Synchronizing” in SQL Server Management Studio for both primary and all secondary availability group replicas… Read more
One of the most important tasks on a DBA’s to-do list is backing up databases on a regular basis. This is because reliable backups are the most important tool in ensuring data recovery. Therefore, it is important for the DBA to check for database backups and validate that they have… Read more
Today, we experienced performance issues with some of the SSRS reports that were deployed as part of the latest application/database release. While investigating this performance problem, I realized that the underlying tables for these report queries do not have clustered index. I was even more surprised when I realized that… Read more
Today, I received an email from the developer asking if there is a better way instead of the COUNT (*) Transact-SQL statement, to count the number of records in a table. My reply to his question is yes, there are several methods to get this information from SQL Server. However,… Read more
One of the key tasks of a DBA is to maintain the database indexes and make sure they are not fragmented. You can use a sys.dm_db_index_physical_stats in a script to rebuild or reorganize indexes based on fragmentation. However, sometimes we may need to rebuild all indexes on all tables in… Read more
Today, one of the developers come to me and asked me the question that is there any T-SQL function that he could use to remove everything before and after a specific character in string. For example, if the table contains the full names of the people in the format… Read more
Here is the simple query that returns basic information about all tables in a database that are partitioned:
SELECT SCHEMA_NAME([schema_id]) AS [schema_name] ,t.[name] AS [table_name] ,i.[name] AS [index_name] ,i.[type_desc] AS [index_type] ,ps.[name] AS [partition_scheme] ,pf.[name] AS [partition_function] ,p.[partition_number] ,r.[value] AS [current_partition_range_boundary_value] ,p.[rows] AS [partition_rows] ,p.[data_compression_desc] FROM sys.tables t INNER JOIN…
Get performance statistics for queries and query plans that are cached by SQL Server for faster query execution
You can use the following two DMVs to give you that information:
- sys.dm_exec_cached_plans – You can use this dynamic management view to see information about the plans that are cached by SQL Server, along with other information such as cached query text, the amount of memory taken by cached plans,…
Transact-SQL (T-SQL) query to return the status and detail information for all SQL Server Full-Text Catalogs on an SQL Server instance
We have about 200 user databases in which we have the full-text search enabled and these databases contain several tables. As part of my daily checks, I have to check the status of all full-text catalogs, to ensure that all full-text catalogs are successfully populated without errors. However, to check… Read more