Top "Query-performance" questions

For questions about making database queries run faster.

SQL Server IN vs. EXISTS Performance

I'm curious which of the following below would be more efficient? I've always been a bit cautious about using IN …

sql-server sql-server-2005 exists query-performance sql-in
Select distinct values from a table field

I'm struggling getting my head around the Django's ORM. What I want to do is get a list of distinct …

django django-queryset django-orm query-performance
Deleting millions of rows in MySQL

I recently found and fixed a bug in a site I was working on that resulted in millions of duplicate …

mysql query-performance maintenance sql-delete
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 …

sql sql-server query-performance sql-execution-plan
Why is there a HUGE performance difference between temp table and subselect

This is a question about SQL Server 2008 R2 I'm not a DBA, by far. I'm a java developer, who has …

sql sql-server-2008-r2 subquery query-performance temp-tables
How do NULL values affect performance in a database search?

In our product we have a generic search engine, and trying to optimze the search performance. A lot of the …

sql database oracle database-performance query-performance
How to force oracle to not to use an index

I have a requirement in which i have to force the sql not to use a particular index which exists …

sql oracle query-performance hints
Query times out when executed from web, but super-fast when executed from SSMS

I'm trying to debug the source of a SQL timeout in a web application that I maintain. I have the …

sql-server sql-server-2008 ssms query-performance arithabort
Does getting entities with AsNoTracking() disable the automatic call to DetectChanges()?

I've come to know this concept of AsNoTracking(), DetectChanges(), and AutoDetectChangesEnabled very recently. I understand that when fetching records from …

entity-framework ef-code-first query-performance
Performance of nested select

I know this is a common question and I have read several other posts and papers but I could not …

sql performance database-performance query-performance