If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
IsNull
I've tried and tried to rewrite the following section of my sql statement to
no avail using IsNull in place of Nz. I need to use this query in a web application and must convert the Nz to IsNull. IIf([OTHours]10,Sum([OTHours]+Nz(([OTType]/1000000)+([OTRefusal]/10000000),0) I've tried IIf([OTHours]10,Sum([OTHours]+IsNull(([OTType]/1000000)+([OTRefusal] /10000000),0,([OTType]/1000000)+([OTRefusal]/10000000)) but receive the wrong number of argument error. -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...eries/200702/1 |
#2
|
|||
|
|||
IsNull
Hi Mike,
try it ---- SUM(IIF([OTHours]10,[OTHours]+IIF(isnull([OTType]+[OTRefusal])=True,0,([OTType]/1000000+[OTRefusal]/10000000)),0)) ---- bye -- Giorgio Rancati [Office Access MVP] "Mike Will via AccessMonster.com" u15958@uwe ha scritto nel messaggio news:6db5d1d68490b@uwe... I've tried and tried to rewrite the following section of my sql statement to no avail using IsNull in place of Nz. I need to use this query in a web application and must convert the Nz to IsNull. IIf([OTHours]10,Sum([OTHours]+Nz(([OTType]/1000000)+([OTRefusal]/10000000),0) I've tried IIf([OTHours]10,Sum([OTHours]+IsNull(([OTType]/1000000)+([OTRefusal] /10000000),0,([OTType]/1000000)+([OTRefusal]/10000000)) but receive the wrong number of argument error. -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...eries/200702/1 |
#3
|
|||
|
|||
IsNull
Kudos! That worked out great. Thank you.
-- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...eries/200702/1 |
Thread Tools | |
Display Modes | |
|
|