Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How do you hide NULL from the UI?
Message
 
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01462853
Message ID:
01463118
Views:
29
>>>>So, how do you want to solve this problem? You can also make this textbox invisible in case of empty if that's what you meant by hiding.
>>>
>>>I will let you know if and when I find the solution to this.
>>
>>Can you explain exactly what you're trying to achieve? What is your front-end application?
>
>Only if you promise not to bombard me with suggestions <g>
>
>Here it is in a simplified description.
>
>Parent table: Look up for various references. This table has 3 columns:
>1 - PK (Identity)
>2 - AK (Candidate/Unique field) field REFERENCE (char 10). Examples: MAILED, FAXED, EMAILED.
>3 - Description field (DESCRIPTION char(50)). Description of the value in the REFERENCE field.
>
>Child table: Has FK field REFERENCE. User selects entry from a look up or enters value manually. For RI the value user enters has to be in the field REFERENCE of Parent table.
>Sometimes, user wants to blank (delete the entry) from the child table (for whatever reason). If he/she does it and saves the record, the RI constraint will not let them.
>
>So I would need to have a record/row in the Parent table with the value in field/column REFERENCE blank.
>
>That's all.

Dmitry,

This is how I would solve it.

Don't add empty record to the Parent table.

When the user deletes a value in the reference field, convert it to NULL behind the scenes (when it's time to save).

That's all what is needed, IMHO.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform