Viewing 15 posts - 181 through 195 (of 375 total)
maybe this but not guaranteed.
drop table if exists #TEMP1;
drop table if exists #TEMP2;
drop table if exists #TEMP3;
select distinct T1.QUOTE_DATE
into #TEMP1
from dbo.OptionsEOD T1
CREATE CLUSTERED INDEX #CI_TEMP1 ON...
July 3, 2023 at 11:50 pm
try the following code.
and then give us the actual explain plan for both this code and your code.
drop table if exists #TEMP1;
drop table if exists #TEMP2;
select...
July 3, 2023 at 6:12 pm
not much you can do about that query (which is the version I gave you) - the nature of the query does not really allow for pre-filtering or use...
June 23, 2023 at 1:50 am
option 1 is incorrect - just discard it.
can you give the plan for the second? was expecting it to be a bit faster than that.
no problem
here you...
June 18, 2023 at 3:42 am
frederico_fonseca wrote:option 1 is incorrect - just discard it.
can you give the plan for the second? was expecting it to be a bit faster than that.
no problem
here you go
Did...
June 9, 2023 at 2:55 am
option 1 is incorrect - just discard it.
can you give the plan for the second? was expecting it to be a bit faster than that.
no problem
here you go
June 6, 2023 at 5:24 pm
thanks for all the replies. much appreciated.
Some background...I have been making changes to a stored proc. I made a change (not sure exactly what tho) that resulted in incorrect query...
June 6, 2023 at 4:44 pm
regarding your last query (from the second plan). two options below
option 1 is just a adjustment of your original query - does same thing but with 1 less join....
June 6, 2023 at 3:29 pm
can you try this slight variation of my second example and give runtime and plan as well.
drop table if exists #weeklastday;
drop table if exists #temp1;
select distinct...
June 5, 2023 at 3:54 pm
that plan is from you version of the change e.g. where you still keep the dateadd and your temp table does not filter or change the expiration date.
can you...
June 5, 2023 at 5:40 am
how much faster? can can you also put new explain plan.
there is no official cut off. the lowest possible is best. the run time for the entire 1000 line...
June 5, 2023 at 4:40 am
small error on my original code - the temp table was referring an non existing alias (t1)- easy to fix I think.
another attempt at simplifying it assuming that I...
June 5, 2023 at 2:52 am
no difference.
your code was only looking for the the friday date on a particular situation e.g. when the EXPIRATION = Thursday
so by determining all the FRIDAY dates in advance,...
June 5, 2023 at 2:33 am
no difference.
your code was only looking for the the friday date on a particular situation e.g. when the EXPIRATION = Thursday
so by determining all the FRIDAY dates in advance,...
June 5, 2023 at 2:20 am
adding further indexes on this case likely not the best - the underlying table is a columnstore table.
the thing that would speed up the most is to have a...
June 5, 2023 at 2:04 am
Viewing 15 posts - 181 through 195 (of 375 total)