Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
BUG: put null on string variable remember previous put
Message
From
10/04/2004 02:02:01
Gerry Schmitz
GHS Automation Inc.
Calgary, Alberta, Canada
 
 
To
09/04/2004 05:12:10
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00892851
Message ID:
00893776
Views:
20
Either solution will suffice ...and you are now babbling on about "some field" that will not allow NULLS ... or not ...

The point was that you introduced a bug in the first place, and I maintain that your perception of which side of the "curve" you are on is "indeterministic" ... given A problem ... (ie. you are not as smart as you think).

Your "solutions" also illustrate an important precept that most of us ("old timers") understand ... and that is: "maintainabilty". No matter how "smart", "clever", "cute", or whatever, you perceive your solution to be, if no one else "gets it" (in the grand scheme of things), then it is useless (ie. was the result to allow NULLS ? Yes ? No ? Maybe ? Indeterministic ? Gaussian Distribution ? WHAT ?)

We have all travelled the path of trying to implement every obscure feature of a given language; maturity showed us that there is beauty in simplicity.

Keep your observations coming; but spare us the assumptions that we haven't been there already.

>
>Speaking of "standard logic", your "answer" to the "question" actually contains a potential bug due to improper handling of NULLS; the COALASCE, as coded, may still return NULLS in the event that ALL fields contain NULLS and therefore needs an extra NULLs test: eg.
>
>SELECT NULLIF(COALESCE( ..., ..., ...), [...]) AS ...
>
>Or was it your intention to allow NULLs in the result in any event ? If not, let's skip any more talk about "standard developer gaussian distributions" (sic).
>

>
>Why this complication?
>
>
>If i allow NULLs COALESCE() and SurrogateN.myField Nullable are suffiecient.
>
>If i not allow NULL:
>
>solution A:
>
>SurrogateN.myField is NOT Nullable and is filled with the default value
>
>
>solution B:
>
>... COALESCE(M,......,SurrogateN.myField,DefaultValue)
>
Previous
Reply
Map
View

Click here to load this message in the networking platform