Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Numeric Overflow
Message
From
20/02/2015 05:08:06
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
19/02/2015 19:49:35
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Web
Miscellaneous
Thread ID:
01615591
Message ID:
01615621
Views:
69
>>
>>REPLACE field1 WITH IIF(field2 = 1/0, value1, value2)
>
>Thanks Dragan.
>
>I knew that divide by zero produced this error and I tried (at least I think I tried)
>? myfield = 1/0 and kept getting false. Maybe it has something to do with the width of the field N(16).

Haven't used this trick much... the only time I needed it was when migrating data from dbfs to sql, and sql of course won't accept such values, so I had to catch them in advance. But the last such migration was a few years ago, so I don't really remember the details.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Reply
Map
View

Click here to load this message in the networking platform