pinaldave

Stories submitted by pinaldave

SQL SERVER – Queries Waiting for Memory Allocation to Execute(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 7 months ago

In one of the recent projects, I was asked to create a report of queries that are waiting for memory allocation. The reason was that we were doubtful regarding whether the memory was sufficient for the application. The following query can be useful in similar case. Queries that do not have to wait on a memory grant will not appear in the resultset of following query. read more...

add a comment |category: |Views: 191

tags: another

Download Logical Query Processing Poster(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 7 months ago

Earlier this year, I had written article on SQL SERVER – Logical Query Processing Phases – Order of Statement Execution and I had asked one question to readers. I got very good response for this question. Today, I am going to discuss about one of the errata I have made there. I had displayed the Logical Query Processing order, where I had incorrectly listed the last two operations. I have listed the operations as ORDER BY first and TOP afterwards. The fact is that TOP is always executed first and ORDER BY after that. read more...

1 comment |category: |Views: 351

tags: another

Intorduction to Service Broker and Sample Script(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 7 months ago

Service Broker in Microsoft SQL Server 2005 is a new technology that provides messaging and queuing functions between instances. The basic functions of sending and receiving messages forms a part of a “conversation.” Each conversation is considered to be a complete channel of communication. Each Service Broker conversation is considered to be a dialog where two participants are involved. read more...

add a comment |category: |Views: 152

tags: another

Insert Values of Stored Procedure in Table – Use Table Valued Function(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 7 months ago

I recently got many emails requesting to write a simple article. I also got a request to explain different ways to insert the values from a stored procedure into a table. Let us quickly look at the conventional way of doing the same. Please note that this only works with the stored procedure with only one resultset. Let us create a stored procedure that returns one resultset. read more...

add a comment |category: |Views: 73

tags: another

Interesting Observation – Execution Plan and Results of Aggregate Conc(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 7 months ago

Working with SQL Server has never seems to be monotonous – no matter how long one has worked with it. Quite often, I come across some excellent comments that I feel like acknowledging them as blog posts. Recently, I wrote an article on SQL SERVER – Execution Plan and Results of Aggregate Concatenation Queries Depend Upon Expression Location, which is well received in community. read more...

add a comment |category: |Views: 132

tags: another

Execution Plan and Results of Aggregate Concatenation Queries Depend U(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 8 months ago

I was reading the blog of Ward Pond, and I came across another note of Microsoft. I really found it very interesting. The given explanation was very simple; however, I would like to rewrite it again. Let us execute the following script. This script inserts two values ‘A’ and ‘B’ in the table and outputs a simple code to concatenate each other to produce the result ‘AB’. read more...

add a comment |category: |Views: 48

tags: another

Interesting Observation – Index on Index View Used in Similar Query(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 8 months ago

I was working on an optimization project for one of the large organizations. While working on one of the queries, we came across a very interesting observation. We found that there was a query on the base table and when the query was run, it used the index, which did not exist in the base table. On careful examination, we found that the query was using the index that was on another view. This was very interesting as I have personally never experienced a scenario like this. In simple words, “Query on the base table can use the index created on the indexed view of the same base table.” read more...

add a comment |category: |Views: 62

tags: another

SQL SERVER – Importance of Database Schemas in SQL Server(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 8 months ago

Beginning with SQL Server 2005, Microsoft introduced the concept of database schemas. A schema is now an independent entity- a container of objects distinct from the user who created those objects. Previously, the terms ‘user’ and ‘database object owner’ meant one and the same thing, but now the two are separate. This concept of separation of ‘user’ and ‘object owner’ may be a bit puzzling the first time one encounters it. read more...

1 comment |category: |Views: 252

tags: another

What is Data Mining – A Simple Introductory Note(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 8 months ago

According to MacLennan et al. (2009), data mining is defined as “the process of analyzing data to find hidden patterns using automatic methodologies.” Consider the following simple example that explains this concept. By analyzing the data on the items purchased from a supermarket or a chain of such stores, information on the products that are sold most can be obtained and accordingly supply of that particular products are increased and vice versa. Data mining, in short, is an analytical activity that studies the hidden patterns in a huge pile of data after appropriately classifying and sorting it. read more...

4 comments |category: |Views: 268

tags: another

Mirrored Backup and Restore and Split File Backup(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 8 months ago

This article is based on a real life experience of the author while working with database backup and restore during his consultancy work for various organizations. We will go over the following important concepts of database backup and restore. 1. Conventional Backup and Restore 2. Spilt File Backup and Restore 3. Mirror File Backup 4. Understanding FORMAT Clause 5. Miscellaneous details about Backup and Restore read more...

add a comment |category: |Views: 90

tags: another

SQL Server Express – A Complete Reference Guide(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 8 months ago

SQL Server Express is one of the most valuable products of Microsoft. Very often, I face many questions with regard to SQL Server Express. Today, we will be covering some of the most commonly asked questions. Let me give you quick list of the online help resources. Even though I took some time to build this reference list, I am sure that all of you will appreciate this and will share with others, which is worth the effort! read more...

add a comment |category: |Views: 31

tags: another

A Delayed Analysis(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 8 months ago

What is your opinion? read more...

add a comment |category: |Views: 4

tags: another

Measure CPU Pressure(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 9 months ago

Let us understand the simple meaning of CPU pressure. CPU pressure is a state wherein the CPU is fully occupied with currently assigned tasks and there are more tasks in the queue that have not yet started. read more...

add a comment |category: |Views: 257

tags: another

Get Query Plan Along with Query Text and Execution Count(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 9 months ago

Quite often, we need to know how many any particular objects have been executed on our server and what their execution plan is. I use the following handy script, which I use when I need to know the details regarding how many times any query has ran on my server along with its execution plan. You can add an additional WHERE condition if you want to learn about any specific object. read more...

add a comment |category: |Views: 140

tags: another

Reason for SQL Server Agent Starting Before SQL Server Engine Service(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 9 months ago

Nakul, a dedicated member of the Gandhinagar SQL Server User Group, recently emailed me with a very interesting, but quick question. He asked me why the SQL Server Agent starts before SQL Server Engine does? He made the very valid point that as the SQL Server Engine is the core service, it should start first, and there is little point to running the SQL Server Agent without it. Off the top of my head, I can offer the following quick reasons for this sequence: What are you thoughts on this subject? read more...

1 comment |category: |Views: 95

tags: another

SQL SERVER – Introduction to SQL Server 2008 Profiler(blog.sqlauthority.com)

submitted by pinaldavepinaldave(9662) 2 years, 9 months ago

Introduction SQL Server Profiler is a powerful tool that is available with SQL Server since a long time; however, it has mostly been underutilized by DBAs. SQL Server Profiler can perform various significant functions such as tracing what is running under the SQL Server Engine’s hood, and finding out how queries are resolved internally and what scripts are running to accomplish any T-SQL command. The major functions this tool can perform have been listed below: * Creating trace * Watching trace * Storing trace * Replaying trace read more...

add a comment |category: |Views: 228

tags: another