Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ltrim & rtrim returning null 1

Status
Not open for further replies.

kaht

Programmer
Aug 18, 2003
4,156
US
when I run the following command:

ltrim(rtrim('')) I am getting a value of NULL returned.

up until earlier today this command has always returned ''

is there a setting that can be changed that will cause this command to return different values?

the odd thing is that if I change to a different database and run the command I get the empty string as expected, so I expect that there has been some setting that has been switched for this particular database


thanks in advance

-kaht

[small]How spicy would you like your chang sauce? Oh man... I have no idea what's goin' on right now...[/small]
[banghead]
 
Are you and Will192 the same person? Or do you work together?

THREAD183-1234179

-SQLBill

Posting advice: FAQ481-4875
 
Yeah, we work together. When I said that I'd post to the forum about this question I didn't think that he'd post to the same one....

Anyway, the problem is fixed - a compatibility setting of 65 caused the command to return null, switching it to 80 (like all the other databases) fixed the situation.


Now.... to find out how in the world it got set to 65 in the first place......

-kaht

[small]How spicy would you like your chang sauce? Oh man... I have no idea what's goin' on right now...[/small]
[banghead]
 
I fixed it. Somehow the compatibility level got set to 65 and my recovery model got changed also. Not sure how this happened and I can't find anything in the logs to see when it happened.

Thanks for the help.
 
Is this a database that you created? Or is it a vendor's database?

We had a vendor created database where the vendor supplied an update and without informing anyone they decided their update would set the database to the SIMPLE mode. It didn't change the compatibility level, but it did change the recovery mode.

-SQLBill

Posting advice: FAQ481-4875
 
Thanks for the tips guys, will isn't gonna leave any stars I'm sure so have a pair on me.

-kaht

[small]How spicy would you like your chang sauce? Oh man... I have no idea what's goin' on right now...[/small]
[banghead]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top