Viewing 15 posts - 4,696 through 4,710 (of 5,588 total)
Okay, try N <= len(@input). It doesn't fix your issue, but it does now work on the whole string.
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
March 2, 2010 at 11:05 am
Lowell,
If you substitute this for the end of your code, you will see that @input does not end with a CRLF... just a CR. Maybe this is it?
...
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
March 2, 2010 at 11:00 am
Exactly what I was thinking. (also didn't like 4 updates going on...)
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 10:41 pm
The "correct" answer doesn't have a column in the where clause... how can that be SARGable?
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 10:38 pm
ray-SQL (2/25/2010)
Try this, not sure it handles all of your scenarios, so more sample data would be good. But it is working for what you given us.
I've modified what you...
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 9:53 pm
ray-SQL (2/25/2010)
Try this, not sure it handles all of your scenarios, so more sample data would be good. But it is working for what you given us.
It's looking good to...
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 9:23 pm
callum.bundy (2/25/2010)
After having a discussion with someone regarding how SSMS organises databases in the list (i.e. alphabetically) I was wondering if anyone had ever created an addon for it that...
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 9:07 pm
Daniel Hallam (2/25/2010)
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 9:05 pm
Asha.Richardson-1129890 (2/25/2010)
Basically, your change worked as long as I put in a few column names, but when i just ran your query, I got this message:
Msg 421, Level 16,...
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 9:02 pm
GilaMonster (2/25/2010)
Compat mode is controlled by the current DB context, not the source and destination of the data
Okay, I made it through the day and finally learned something new! Good...
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 3:21 pm
Asha.Richardson-1129890 (2/25/2010)
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 3:14 pm
dbaltazar (2/25/2010)
The sample data already given is realistic but I'll work on getting more.
This would be appreciated.
AcctID+FundID are the key between the 2 tables.
Okay, understood.
I want to loop thru payment...
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 10:58 am
Yes... and all of your sample data is for 1 account, and 1 fund, on one date. How do we tell that the $75 payment goes to the first pledge,...
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 10:41 am
First, please provide the table structure information, and test data via "CREATE TABLE" / "DECLARE @TableVar TABLE" and "INSERT" statements (see the first link in my signature for how to...
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 10:37 am
Based on what Lowell started, how does this work for you?
select case convert(tinyint,PARSENAME(convert(varchar(20),SERVERPROPERTY('productversion')),4))
when 8 then 2000
...
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 25, 2010 at 9:56 am
Viewing 15 posts - 4,696 through 4,710 (of 5,588 total)