Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Empty() vs 2 quotes
Message
 
 
To
18/10/2011 16:02:46
James Blackburn
Qualty Design Systems, Inc.
Kuna, Idaho, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
Miscellaneous
Thread ID:
01526798
Message ID:
01526807
Views:
68
>>update States set State = 'SP' where Len(State) = 0 && Empty state
>
>I am not sure that is such a good idea.
>
>len(null) returns .null.
>len(' ') returns 2
>empty(null) returns .f.
>
>In this case I use empty(nvl(state,""))

You're right, I was thinking about SQL Server. Although in SQL Server LEN(NULL) will return null.
If it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform