Viewing 15 posts - 271 through 285 (of 1,082 total)
also remember that each @sql in an EXEC(@SQL) will only allow for 4000 charaters to be run.
So if it's long you need to do something like this
EXEC (@SQL + @SQL1)...
March 24, 2009 at 7:57 am
I guess the other thing to remember , I have picked up from some more research is that they do have slightly different characteristics...
TOP can be used in subqueries etc.
SET...
March 24, 2009 at 6:46 am
mmm I don't get a hash
I get loops in both. but there is an extra operator for the top...
but like you I'm unsure which is better
I'll do some more...
March 24, 2009 at 6:17 am
ah I see,
I'm sorry but my knowledge of memory consumption is limited but my guess is going to be that the first statement is the best.
2 is out cause SQL...
March 24, 2009 at 5:44 am
1 and 2 are almost the same.
your string can be converted to a decimal directly from
'12344.83937898' to .12344.83937898
Now when converting a numeric/decimal to a numeric/decimal, rounding occurs, you can...
March 24, 2009 at 5:29 am
ok cool,
but how do you determine priority of minuterate?
There is no idea or order by in that table?
or will the 1800% always take preference over 1_______?
March 24, 2009 at 3:14 am
I'm assuming there is not competition anymore?
March 23, 2009 at 10:47 am
Is this the kind of thing you trying to do?
SELECT *
FROM Table1 a
INNER JOIN Table2 b
ONPATINDEX(b.Pattern,finalCalledPartyNumber) != 0
Not the best solution yet, cause you will get no index usage...
March 23, 2009 at 9:58 am
I under stand that the 1800% would match to row 1 of your table1 in the example.
I'm unsure what the 1__________ will match to in table1 and Why?
Thanks
Chris
March 23, 2009 at 9:55 am
I'm with Grant on this one.
I don't think a day goes past without me using BOL, however I wouldn't recommended to someone learning SQL for the first time.
March 23, 2009 at 7:09 am
I think the OP does have joins in his Code however they are using the old SQL syntax.
OP If you are new to SQL it is highly recommended that you...
March 23, 2009 at 7:04 am
Here is a pretty good article by Jeff, about dynamic pivoting using cross-tabs which seem to be faster than actually using the PIVOT function in 2005.
check it out:
March 23, 2009 at 4:50 am
try this
WHERE
(@pAnnualReviewFlag = 1
AND
(Coalesce(annual_review_type_id,0) IN (1,5))
OR
(@pAnnualReviewFlag != 1
AND
(Coalesce(annual_review_type_id,0) IN (2,6))
March 23, 2009 at 4:44 am
Sorry to bring this up, but has anyone else got some advice on this ?
March 20, 2009 at 11:22 am
also if you give us an example of some data then we could help you.
I don't understand the syntax you have pasted so I'm not 100% sure what you pivoting.
March 20, 2009 at 10:39 am
Viewing 15 posts - 271 through 285 (of 1,082 total)