Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Sql column not wide enough.
Message
From
17/11/1998 15:24:36
George Lee
Microcomputer Engineering Services, Llc
Huntington Beach, California, United States
 
 
To
17/11/1998 15:15:30
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00158450
Message ID:
00158474
Views:
22
>>>I want to have an SQL statement that will allow an IIF that can accept up to 2 digits.
>>>
>>>
>>>
>>>SELECT *, ;
>>> IIF( INLIST( nUserSecurityLevel, 1, 2, 3 ), nUserSecurityLevel+00, 99 ) AS ; nUserLvl ;
>>> FROM ;
>>> UserSecurity
>>>
>>>
>>>Excellent. Thank you for your 34 second response :).
>>>
>>>Dan
>>
>>Sorry about the blank post.. How would I handle it if the above used characters instead.
>>'A', 'B', 'C' and "ZZ".
>>
>>Dan
>
>'A ', 'B ', 'C ' and "ZZ"

I tried that and it didn't seem to work. But when using the same idea as above for the number that fixed the problem.

"<"pre">"

SELECT *, ;
IIF( INLIST( cUserSecurityLevel,'A','B', 'C' ), cUserSecurityLevel+' ', 'ZZ' ) AS ; cUserLvl ;
FROM ;
UserSecurity
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform