Viewing 15 posts - 61 through 75 (of 111 total)
rjv_rnjn (10/29/2009)
465789psw (10/29/2009)
set @strbig = '"db=' + @db + ' and (' + @word + '' + ')"'.That will give you the desired output.
I didn't realize you had...
October 29, 2009 at 8:20 am
465789psw (10/29/2009)
set @strbig = '"db=' + @db + ' and (' + @word + '' + ')"'.
That will give you the desired output.
October 29, 2009 at 8:09 am
I would guess some row contains character value for column "category_1.Description" that's making the conversion to fail.
October 28, 2009 at 12:07 pm
You may want to look at creating an SSIS package and then set it as a job in SQL Server.
October 28, 2009 at 12:05 pm
G² (10/1/2009)
SQL Server 2008 introduces several extensions to the GROUP BY clause that enable you to define multiple groupings in the...
October 1, 2009 at 11:13 am
Whenever I have faced such situations with dynamic SQL; invariably the issue has been some variable being null ( as @arun.sas said and demonstrated).
September 29, 2009 at 11:28 am
Try this:
select case when id is null then 'N/A' else convert(varchar, sum(id)) end from tN group by id
The convert function has been used to get the 'N/A' value. You can...
September 29, 2009 at 11:23 am
Lowell's first post has the Order By. You'll just have to re-arrange the order of fields. Also note that you should be placing the Order By only towards the end...
September 22, 2009 at 11:27 am
I'm not sure if this is the cause of the error but with dynamic sql I always use
EXEC (@sql)
September 22, 2009 at 9:12 am
The name I'm thinking of (a slang term) could actually be more related to the From clause than the join. Another example would be like this:
That's poorly written. But I...
September 22, 2009 at 9:04 am
I doubt that's a join because there are no columns specified for the join to base on.
@matt-2, As the where clause is not mentioned in the query I...
September 22, 2009 at 8:44 am
Yeah, for certain user selected options the number of columns could be as big as 36(maximum now but may grow couple years down the line).
I will surely post the .Net...
September 16, 2009 at 3:49 pm
Thank you @Bitbucket for the suggestion but as @Garadin pointed out the situation is not as simplistic. I'd the test data to give an idea of...
September 16, 2009 at 1:49 pm
Hmm. I won't take that route then. I can do the required in front-end, and I'll have to run a loop for the number of columns and it's not that...
September 16, 2009 at 10:58 am
PIVOT may help you.
A good article on it here: http://qa.sqlservercentral.com/articles/T-SQL/63681/
September 16, 2009 at 9:47 am
Viewing 15 posts - 61 through 75 (of 111 total)