[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Null value into an integer variable
[Thread Prev] | [Thread Next]
- Subject: Re: Null value into an integer variable
- From: BB <adamnt42@xxxxxxxxx>
- Date: Fri, 19 Apr 2024 21:28:04 +0930
- To: user@xxxxxxxxxxxxxxxxxxxxxx
On 19/4/24 8:23 pm, Rolf-Werner Eilert wrote:
The only problem with that is when the data is subsequently updated to the database it will be 0 instead of "not set yet". Further 0 may be an actual value for say "the account balance" when Null is the correct value at the time.Usually I try to catch this case by checking for "" and IsNull(Val(...)) likeIf sMyString = "" Then iMyInteger = 0 Else If IsNull(Val(sOriginal)) Then iMyInteger = 0 Else iMyInteger = Val(sOriginal) End If End If to be completely sure. Regards Rolf
b
GRIDVIEW color and size | "Mayost Sharon" <sharon@xxxxxxxxx> |
Re: GRIDVIEW color and size | T Lee Davidson <t.lee.davidson@xxxxxxxxx> |
Re: GRIDVIEW color and size | T Lee Davidson <t.lee.davidson@xxxxxxxxx> |
Re: GRIDVIEW color and size | "Mayost Sharon" <sharon@xxxxxxxxx> |
Re: GRIDVIEW color and size | T Lee Davidson <t.lee.davidson@xxxxxxxxx> |
Null value into an integer variable | "Mayost Sharon" <sharon@xxxxxxxxx> |
Re: Null value into an integer variable | BB <adamnt42@xxxxxxxxx> |
Re: Null value into an integer variable | Rolf-Werner Eilert <rwe-sse@xxxxxxxxxx> |