Viewing 15 posts - 496 through 510 (of 1,183 total)
Without looking too deeply, because I don't have the time right now. You should get a performance boost by removing the ORDER BY's
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 21, 2008 at 8:03 am
Good catch Sergiy 😛
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 21, 2008 at 7:11 am
No need to PIVOT or CROSSTAB, even though they'll both work ....
-- create a table for sample data
DECLARE @t TABLE
(RowID Char(16)
,Code1...
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 20, 2008 at 8:37 am
if you later have
table1.col4 = table2.col4
in the where clause then it's an inner join
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 15, 2008 at 3:05 pm
Nope, in that use they are equivalent.
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 15, 2008 at 2:23 pm
Please post the code you've tried.
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 14, 2008 at 2:10 pm
Matt Miller (5/14/2008)
SELECT
a.name
,reg_hrs
...
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 14, 2008 at 10:40 am
Under Properties > Options for the database. But if it's SQL 2000, the CTE will not work.
Try this instead.
SELECT
a.name
,reg_hrs
...
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 14, 2008 at 10:04 am
Are you using SQL 2005?
Compatibility Level set to 90?
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 14, 2008 at 9:57 am
Place a semi-colon at the end of the line immediately before the WITH statement.
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 14, 2008 at 9:26 am
I'm not sure I understand why you want a "variable" Are you trying to avoid performing the aggregation more than one time?
If so then ....
WITH totals
AS (SELECT
...
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 14, 2008 at 9:16 am
The model database is "copied" when you create a new database. So if you create a table in it, such as a tally or numbers table. Then all subsequent databases...
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 13, 2008 at 1:08 pm
Search for SPLIT function on this site. You'll most likely need a variation of that.
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 13, 2008 at 11:25 am
Lookup LTRIM in BOL.
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 13, 2008 at 9:02 am
Helen Thorley (5/13/2008)
This works perfectly for me when run once - but won't "re-run".
Every subsequent attempt results in an report status of 'Root element is missing'.
I've checked the Subscriptions and...
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgMay 13, 2008 at 7:12 am
Viewing 15 posts - 496 through 510 (of 1,183 total)