Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using NVL and Integer types
Message
 
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00445750
Message ID:
00445817
Views:
13
>>>All,
>>>
>>>I have a SQL view using NVL to eliminate .NULLs. from the view fields. I am getting a "View definition has been changed" error message. I think the NVL for the integer types may not have the correct field length.
>>>
>>>How many zeros do I need to use in the NVL to represent an integer?
>>>
>>>TIA
>>>
>>>Rex
>>
>>You need to specify the largest possible value within your data.
>>
>>FWIW, an integer can be + or - 2147483647 so you need to specify 10 so the corresponding result set creates a N(10,0) for storage.
>
>Since it may be negative, wouldn't you need 11 N(11,0)?

Yes it does. I thought about that while I was posting my original response but I was "hoping" VFP would store the sign internally and not need another place holder for it.

"Hoping" is defined as thinking you know the outcome and not testing for it.

< slinks away quietly >
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Previous
Reply
Map
View

Click here to load this message in the networking platform