[prev in list] [next in list] [prev in thread] [next in thread] 

List:       mysql-win32
Subject:    Return NULL result set
From:       mfatene () free ! fr
Date:       2005-04-24 10:25:21
Message-ID: 1114338321.426b741104e6b () imp5-q ! free ! fr
[Download RAW message or body]

Hi,
 Just use the right variables names and it will work.
 You just name your variables :
         @IntPaidToMontht
         @IntPaidToMont  <--- This is NULL

 Mathias

> --------------------------------------------
> This is not an official Mysql support answer
> --------------------------------------------


> Greetings,
>
> Query
> =====
> SET @MonthlyInterest := 1000;
> SET @IntPaidToMontht := 900;
> SET @UP_ActualWDBI   := 500;
>
> UPDATE
>   table1
> SET
>   Interest = IF(@MonthlyInterest - @IntPaidToMonth >=
> @UP_ActualWDBI,
>                 @UP_ActualWDBI,
>                 @MonthlyInterest - @IntPaidToMont),
>
>   Capital  = IF(@MonthlyInterest - @IntPaidToMonth >=
> @UP_ActualWDBI,
>                 0,
>                 @UP_ActualWDBI - (@MonthlyInterest -
> @IntPaidToMont));
>
>
> RESULT SET
> ==========
> Interest := NULL
> Capital  := NULL
>
>
> What wrong with my query?
>
> I thought I should get 100 for Integer and 400 for
> Capital!
>
> Meanwhile, I'm using MySQL 4.1.10 and defined Integer
> and Capital as BIGINT UNSIGNED in table1.
>
> Thanks in advance.
>
>
>
> __________________________________
> Yahoo! Messenger
> Show us what our next emoticon should look like. Join the fun.
> http://www.advision.webevents.yahoo.com/emoticontest
>
> Thread
>
>     * Return NULL result set - ascll, April 3 2005 5:00pm
>
>
>
>



-- 
MySQL Windows Mailing List
For list archives: http://lists.mysql.com/win32
To unsubscribe:    http://lists.mysql.com/win32?unsub=mysql-win32@progressive-comp.com

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic