V4RB2 Method-Question

Ruslan Zasukhin sunshine at public.kherson.ua
Thu Mar 31 10:35:55 CST 2005


On 3/31/05 7:04 AM, "Claudius Sailer" <Claudius at sailer-online.de> wrote:

Hi Claudius,

> you can see, that I use in following database table class a method. It
> is possible that LastValue gets as value 0 or NULL and then I should
> have division by 0 or NULL. Brings this trouble and I should make an
> if-statement around or is it okay to let method as it is in the moment?

If you try do any illegal operation as DIV on zero,
The result will be NULL.

So you can use it as is
 
>    name="Currencies"
>    CUR=new VVarChar("CUR",504,EVFlag.fUnique +EVFlag.fIndexed)
>    CURName=new VVarChar("CURName",504, EVFlag.fUnique +EVFlag.fIndexed)
>    Ric=new VVarChar("Ric",504,EVFlag.fIndexed+EVFlag.fNullable)
>    Online=new VObjectPtr("Online",inDataBase.TOnline,EVFlag.fNullable +
> EVOnDeletion.kRestrict)
>    LastValue=new VLong("LastValue",EVFlag.fNullable)
>    QuotationUnit=new VULong("QuotationUnit")
>    QuotationMode=new VBoolean("QuotationMode")
>    NValue=new VFloat("NValue", EVFlag.fNone,
> "if(QuotationMode=1,(LastValue/10000)/QuotationUnit,1/((LastValue/
> 10000)/QuotationUnit))")
>    Sortierung=new VULong("Sortierung")

-- 
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina - Joining Worlds of Information
http://www.paradigmasoft.com

[I feel the need: the need for speed]




More information about the Valentina mailing list