Skip to main content
How are we doing? Please help us improve Stack Overflow. Take our short survey

All Questions

Tagged with
381 votes
13 answers
513k views

How do I obtain a Query Execution Plan in SQL Server?

In Microsoft SQL Server how can I get a query execution plan for a query / stored procedure?
Justin's user avatar
  • 86.1k
97 votes
6 answers
104k views

SQL Server Plans : difference between Index Scan / Index Seek

In a SQL Server Execution plan what is the difference between an Index Scan and an Index Seek I'm on SQL Server 2005.
cindi's user avatar
  • 4,731
93 votes
11 answers
65k views

How do you interpret a query's explain plan?

When attempting to understand how a SQL statement is executing, it is sometimes recommended to look at the explain plan. What is the process one should go through in interpreting (making sense) of an ...
user avatar
62 votes
3 answers
222k views

How do I view the Explain Plan in Oracle Sql developer?

I have few SQL queries which has very low query running performance and I want to check the query execution plan for this query. I am trying to execute the below query but its not showing any query ...
Andrew's user avatar
  • 3,730
62 votes
5 answers
43k views

SQL explain plan: what is Materialize?

I asked PostgreSQL to explain my query. Part of the explanation was: table_name --> Materialize What does materialize do? I'm joining two tables, not views or anything like that.
Claudiu's user avatar
  • 227k
55 votes
6 answers
139k views

Measuring Query Performance : "Execution Plan Query Cost" vs "Time Taken"

I'm trying to determine the relative performance of two different queries and have two ways of measuring this available to me: 1. Run both and time each query 2. Run both and get "Query Cost" from the ...
MatBailie's user avatar
  • 85.8k
52 votes
7 answers
25k views

Meaning of "Select tables optimized away" in MySQL Explain plan

What is the meaning of Select tables optimized away in MySQL Explain plan? explain select count(comment_count) from wp_posts; +----+-------------+---------------------------+---------------------...
Chandra Patni's user avatar
48 votes
5 answers
62k views

What "Clustered Index Scan (Clustered)" means on SQL Server execution plan?

I have a query that fails to execute with "Could not allocate a new page for database 'TEMPDB' because of insufficient disk space in filegroup 'DEFAULT'". On the way of trouble shooting I am ...
Bin's user avatar
  • 3,794
41 votes
9 answers
92k views

How to improve performance on a clustered index seek

I'm trying to improve the performance on a query that is running very slowly. After going through the Actual Execution Plan; I found that a Clustered Index Seek was taking up 82%. Is there any way for ...
Abe Miessler's user avatar
  • 84.3k
31 votes
1 answer
46k views

How to Clear down Query Execution Statistics in SQL Server 2005/2008

Based on getting Query Execution Statistics using this extremely useful piece of SQL obtained from this post Most Executed Stored Procedure - Stack Overflow: SELECT TOP 100 qt.TEXT AS 'SP Name', ...
Simon Mark Smith's user avatar
29 votes
3 answers
27k views

How can I analyse a Sqlite query execution?

I have a Sqlite database which I want to check the indexes are correct. MS SQL Analyser is great at breaking down the query execution and utilised indexes. Is there a similar tool for Sqlite?
Phil Hannent's user avatar
  • 12.2k
26 votes
9 answers
13k views

Performance of SQL "EXISTS" usage variants

Is there any difference in the performance of the following three SQL statements? SELECT * FROM tableA WHERE EXISTS (SELECT * FROM tableB WHERE tableA.x = tableB.y) SELECT * FROM tableA WHERE EXISTS ...
Sebastian Dietz's user avatar
24 votes
4 answers
3k views

Missing STOPKEY per partition in Oracle plan for paging by local index

There is next partitioned table: CREATE TABLE "ERMB_LOG_TEST_BF"."OUT_SMS"( "TRX_ID" NUMBER(19,0) NOT NULL ENABLE, "CREATE_TS" TIMESTAMP (3) DEFAULT systimestamp NOT NULL ENABLE, /* other ...
Tsimon Dorakh's user avatar
22 votes
8 answers
11k views

Will my index be used if all columns are not used?

I have an index on columns A, B, C, D of table T I have a query that pulls from T with A, B, C in the WHERE clause. Will the index be used or will a separate index be needed that only includes A, B, ...
user avatar
20 votes
3 answers
35k views

How do I know if any index is used in a query | PostgreSQL 11?

I am little bit confused and need some advice. I use PostgreSQL 11 database. I have such pretty simple sql statement: SELECT DISTINCT "CITY", "AREA", "REGION" FROM youtube WHERE "CITY" IS NOT ...
Nurzhan Nogerbek's user avatar

15 30 50 per page
1
2 3 4 5
36