Viewing 15 posts - 31 through 45 (of 374 total)
Lowell,
Thank you so much for trying to help me.
The code is running on SQL Server 2000 machine.
row_number() will not work.
September 2, 2009 at 1:12 pm
Sorry Lowell.
You are absolutely right I should have posted some SQL code
to re-produce my task.
Lowell,
I probably need to explain a bit what COB and TimeStamp columns are.
[COB] is Close-Of-Business date....
September 2, 2009 at 12:27 pm
I updated the ATTACHMENTS post.
Go to:
http://www.sqlservercentral.com/Forums/Topic780116-360-2.aspx
and look for the post that starts with:
ATTACHMENTS. UPDATED!
-------------------------
September 1, 2009 at 1:17 pm
I inserted prints everywhere.
For example, this query
if @statsFlag = 1 print '\\\ insert #CreditSpreadCurve_subset'
insert
#CreditSpreadCurve_subset
(COB,
Instrument,
Spread)
select
COB,
Instrument,
Spread
from
CreditSpreadCurve
where
COB = @COB1 or COB = @COB2
if @statsFlag = 1 print...
September 1, 2009 at 1:07 pm
I am stll not sure how to count queries.
Here is what I mean.
This query has 4 lines:
print 'location=1'
select count(*) from BondSpread where COB = '8/31/2009'
print 'location=2'
select count(*) from BondSpread where...
September 1, 2009 at 11:57 am
I used SET STATISTICS ON option
and it returned:
...
SQL Server Execution Times:
CPU time = 63 ms, elapsed time = 88 ms.
SQL Server Execution Times:
...
September 1, 2009 at 11:14 am
I assumed you can figure out what are the slowest parts from that STATISTICS output.
Am I wrong?
Anyway,
I didn't run all the pieces of code separately again today but from
what...
September 1, 2009 at 8:12 am
Gila,
sp_help returns a whole bunch of grids.
Can I get results as Text?
September 1, 2009 at 8:02 am
ATTACHMENTS. UPDATED!
-------------------------
OK.
I saved all 20 grids from Query Analyzer
and pasted to "DSR_Validation.xls". It is attached.
[CreditSpreadCurve] view table definitions and indexes are also attached.
Question.
How do I get table definition with all...
September 1, 2009 at 7:30 am
Gila,
I followed your instructions from
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
but "SET STATISTICS PROFILE ON" generated 20 grids.
Do I have to copy each one of them and paste it to Excel?
September 1, 2009 at 7:16 am
I tried SET SHOWPLAN_TEXT ON
and saved it as TEXT file.
See attachment.
Probably Table Definitions won't help you much
because there is no way we can change anything there.
ALTER view [dbo].[BondSpread] as
select...
August 31, 2009 at 2:49 pm
It's SQL Server 2000.
Is there any way to show you Exec Plan in 2000?
August 31, 2009 at 2:32 pm
I did right click in the Execution Plan Tab but "Save Execution Plan As.." is disabled.
August 31, 2009 at 2:24 pm
Yes, I can post all the stuff.
I just forgot how to save Execution Plan as a text file.
August 31, 2009 at 2:19 pm
The problem is solved.
I just filtered [CreditSpreadCurve] by dates;
"...WHERE COB = @COB1 or @COB2..."
and inserted it in a temp table #CreditSpreadCurve_subset,
then joined with this temp table.
The query ran 21 sec.
Ho-ho!
It's...
August 31, 2009 at 1:35 pm
Viewing 15 posts - 31 through 45 (of 374 total)