Viewing 15 posts - 3,151 through 3,165 (of 4,085 total)
Try using .value() instead of .query. I think that the .query may have an implicit conversion to varchar in it somewhere. With the .value, you can specify an...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 16, 2012 at 7:25 am
He also has a valid point here. We already know that there was a problem with multiple records being returned and both the subquery and the merge will raise...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 16, 2012 at 6:59 am
I think that this performs better, because it only requires one scan of the table instead of two.
SELECT * FROM #tmp
ORDER BY ROW_NUMBER() OVER( PARTITION BY Gender ORDER BY Name...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 15, 2012 at 3:15 pm
It's "next" as in "following", not "next to" as in "adjacent". That still doesn't explain what to do with the "][", since the following character doesn't have an uppercase...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 15, 2012 at 10:01 am
The non-standard WITH CUBE has been deprecated as of SQL 2008 in favor of the standard CUBE(<composite element list>) syntax that was introduced in SQL 2008.
This feature...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 15, 2012 at 8:39 am
themangoagent (5/14/2012)
Is Cross Apply something that can be used on SQL Server 2000 tables?
No, it's SQL 2005 or greater.
Drew
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 14, 2012 at 10:48 am
Just to clarify, here is a quote from BOL (emphasis added).
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 14, 2012 at 10:01 am
Since the error is occurring in your VBA code, not your T-SQL code, you're more likely to get help from a VBA forum.
Drew
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 14, 2012 at 9:06 am
CELKO (5/12/2012)
We do not use BIT flags in SQL; that was assembly language.
T-SQL doesn't have a Boolean data type, so I see no problem with using a BIT to represent...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 14, 2012 at 8:00 am
The CASE function cannot return a Boolean value. You can either rewrite your query to return a pseudo-Boolean value and then check whether that value is equal to "true"...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 14, 2012 at 6:59 am
Sean Lange (5/11/2012)
themangoagent (5/11/2012)
Jeff Moden (5/10/2012)
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 14, 2012 at 6:46 am
I still don't see any sample data. It's hard to rewrite your view if we don't have data to compare the original results with the revised results.
Also, please pick...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 11, 2012 at 10:16 am
This problem is almost certainly due to parameter sniffing. Gail has a good article on Parameter Sniffing[/url]
There are other issues with your code, though. You should use a...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 10, 2012 at 12:29 pm
Viewing 15 posts - 3,151 through 3,165 (of 4,085 total)