Linked Questions

0
votes
1answer
75 views

Same Query plan, no new query competition, same hardware, but stored procedure runs slowly

We have an SSRS report that is based on about 8 stored procedures which was running fine up until a few days ago. The report used to run in about 2 hours. Last Sunday (September 15 2019) it suddenly ...
7
votes
2answers
362 views

Force SQL Server to use fragmented indexes?

I have a quite large table (>10M rows) with frequent crud operations. It has proper indexes, but they get fragmented quickly. Without a periodic index reorganize/rebuild maintenance plan, the index ...
1
vote
3answers
137 views

Slow query in production, bad execution plan or bad index?

I've just fixed a production performance issue by dropping an index and recreate it. I suspect dropping the index also dropped executions plans that used it and one of them happen to be bad. ...
12
votes
1answer
173 views

Is this a symptom of an overloaded server?

I've been trying to diagnose slow-downs in an application. For this I've logged the SQL Server extended events. For this question i'm looking at one particular stored procedure. But there are a ...
1
vote
1answer
89 views

Changing stored procedure parameter results slow stored procedure performance

I have a stored procedure to fetch all users in the database. To do this it queries a view which is composed on two tables: Users (holds basic info like username) and UserPortals (maps users to ...
1
vote
1answer
85 views

Parameter Sniffing - Running query in code vs in management studio

I just had a problem at work where a stored proc, being called by some C# code, was very slow. When I ran the same stored proc with the same parameters in Management Studio, it was very fast. After a ...
0
votes
1answer
29 views

Proc runinng slow once in a while [duplicate]

I am trying to troubleshoot the performance issue on one of the SP which executes throughout the day daily every 20 mins and on avg completes under a min. For past couple of weeks it happens once in ...
2
votes
2answers
81 views

Example of query execution plan where the cardinality estimation makes a difference

I am trying to create an example of a query execution plan which shows that if I have the cardinality estimation for some column of a table I can decide which query execution plan has the least cost. ...
0
votes
0answers
39 views

SQL Server query extremely slow. It fixes itself after rebooting [duplicate]

I have an SQL Server instance running on AWS RDS that is performing badly. A query that usually takes milliseconds to run, is taking minutes, causing my application to time out. This particular query ...
1
vote
2answers
119 views

Query execution time is random, need to identify the root cause

I have a query like below select * from table1 where column2=123 and column3='B' Now the issue faced by us is that this query is executing very slowing sometimes as seen in our performance tracking ...
0
votes
0answers
20 views

Multiple Ad-Hoc Statements taking longer than previous days [duplicate]

We have a Data Warehouse product which runs a number of ad-hoc (IE SQL Text, not stored procs or dynamic SQL) every night. The build took significantly longer last night than previous nights and ...
4
votes
1answer
154 views

How to find inputs that caused different query plans in Query Store

Query store shows that a completely parameterized query has multiple query plans: How can I find the input that is causing such long response times? Why would the same parameterized query end up ...
1
vote
0answers
336 views

Poor Query performance when scalar variables used in Query [duplicate]

Facing a strange issue that a query runs incredibly slow (worse) when scalar variables are used as parameter. Actual Query (Faster) - 9 secs select sum(v.sale_value) as col_0_0_, sum(v.vat_value)...
0
votes
0answers
17 views

any knowledge or experience with dynamic ax [duplicate]

I support a system called "dynamics ax" and sometimes my optimizer picks a good plan, drops it and then picks a bad plan (where the same code is been ran). users who usually wait for 10 seconds start ...
0
votes
0answers
28 views

I have a stored procedure running fine before 4PM every day. After that it runs like a dog [duplicate]

I have a stored procedure running fine before 4PM every day. After that it runs like a dog. I identified which query inside the sp caused the problem. In a good run, the logical IO is about 12 ...

15 30 50 per page