Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
View Bug (reprise)
Message
From
05/02/1999 14:02:32
 
 
To
05/02/1999 13:58:47
Eric Barnett
Barnett Solutions Group, Inc
Sonoma, California, United States
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00184361
Message ID:
00184463
Views:
23
Yes I am - but remember, they CORRECTLY show as .null. in the view when appended.
Ken

>Are you adding records to the view with APPEND BLANK? If so you will get BLANK values (i.e. 0 for a numeric field) instead of the .NULL. you might expect. You have to either specify the .NULL. programmatically, or use a default in the view.
>
>This is one of those cases where VFP doesn't behave like SQL server (which will insert .NULL. for all blank values) but probably should. It's probably this way because DBFs got NULL support late and assuming .NULL. might break a lot of older apps.
>
>INSERT - SQL will cause the same problem if you don't explicitly set the value of the field to .NULL.
>
>>(I posted this yesterday, but it might have got lost in the mix - so here goes again)
>>
>>Ok - noticed a behavior today that I had missed before. I have a table with integer fields. These accept .NULL. values but I did NOT set them up to default null. I also have a view that updates this table. The corresponding view fields to those integer table fields ARE set up to default to .NULL. in the view.
>>
>>Problem/Bug: If I insert new record in view, the fields correctly get .NULL. in the view. However, when I tableupdate, it is being inserted into the table fields as 0 (zero) instead of .NULL. If, however, I actually replace the fields in the view with .NULL. (even though .null. is already there) - either programmatically or with Ctrl-0 - before I tableupdate, it works correctly. Can anyone confirm or comment on this?
>>
>>VFP5.0a / WIN98 / Set Null is offf / can reproduce in command window
>>
>>Thanks,
>>Ken
Ken B. Matson
GCom2 Solutions
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform