IIf Problems

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a query that has the following statement

35 DN Bonus: IIf([Dnpmt Perc Of Total]>=0.35 And [Dnpmt Perc Of
Total]<1,[35% Down Bonus]![Total 35% DN Bonus],0)

This works fine if the total in [35% Down Bonus]![Total 35% DN Bonus] has a
value. But when it is equal to or greater than .35 and has a zero value, I
just get blank results.

Some one suggested a nested IIf statement and I have tried several that
don't work at all.

Does anyone have any suggestions on how to write this?
 
But when it is equal to or greater than .35 and has a zero value, I just
get blank results.
This does not make sense. How can it have zero value and be equal to or
greater than .35?

Maybe you need this --
35 DN Bonus: IIf([Dnpmt Perc Of Total]>=0.35 And [Dnpmt Perc Of
Total]<1,[35% Down Bonus]![Total 35% DN Bonus],0) Or Is Null
 
No this did not work, It just returned all blanks.

KARL DEWEY said:
get blank results.
This does not make sense. How can it have zero value and be equal to or
greater than .35?

Maybe you need this --
35 DN Bonus: IIf([Dnpmt Perc Of Total]>=0.35 And [Dnpmt Perc Of
Total]<1,[35% Down Bonus]![Total 35% DN Bonus],0) Or Is Null


Xjcinhoustonx said:
I have a query that has the following statement

35 DN Bonus: IIf([Dnpmt Perc Of Total]>=0.35 And [Dnpmt Perc Of
Total]<1,[35% Down Bonus]![Total 35% DN Bonus],0)

This works fine if the total in [35% Down Bonus]![Total 35% DN Bonus] has a
value. But when it is equal to or greater than .35 and has a zero value, I
just get blank results.

Some one suggested a nested IIf statement and I have tried several that
don't work at all.

Does anyone have any suggestions on how to write this?
 
Please explain to me how you can it have zero value and be equal to or
greater than .35?


Xjcinhoustonx said:
No this did not work, It just returned all blanks.

KARL DEWEY said:
But when it is equal to or greater than .35 and has a zero value, I just
get blank results.
This does not make sense. How can it have zero value and be equal to or
greater than .35?

Maybe you need this --
35 DN Bonus: IIf([Dnpmt Perc Of Total]>=0.35 And [Dnpmt Perc Of
Total]<1,[35% Down Bonus]![Total 35% DN Bonus],0) Or Is Null


Xjcinhoustonx said:
I have a query that has the following statement

35 DN Bonus: IIf([Dnpmt Perc Of Total]>=0.35 And [Dnpmt Perc Of
Total]<1,[35% Down Bonus]![Total 35% DN Bonus],0)

This works fine if the total in [35% Down Bonus]![Total 35% DN Bonus] has a
value. But when it is equal to or greater than .35 and has a zero value, I
just get blank results.

Some one suggested a nested IIf statement and I have tried several that
don't work at all.

Does anyone have any suggestions on how to write this?
 
I have a table that has the items we will pay a bonus on if the downpayment
is >35% but less that 100% of the total sale ( Table A). I have another
table that we enter the items sold (Table B). I have a query that calculated
the bonus on the items that qualify. That is the total I want it to o get.
I think that my problem is stemming from the total on the the other query
being zero.

KARL DEWEY said:
Please explain to me how you can it have zero value and be equal to or
greater than .35?


Xjcinhoustonx said:
No this did not work, It just returned all blanks.

KARL DEWEY said:
But when it is equal to or greater than .35 and has a zero value, I just
get blank results.
This does not make sense. How can it have zero value and be equal to or
greater than .35?

Maybe you need this --
35 DN Bonus: IIf([Dnpmt Perc Of Total]>=0.35 And [Dnpmt Perc Of
Total]<1,[35% Down Bonus]![Total 35% DN Bonus],0) Or Is Null


:

I have a query that has the following statement

35 DN Bonus: IIf([Dnpmt Perc Of Total]>=0.35 And [Dnpmt Perc Of
Total]<1,[35% Down Bonus]![Total 35% DN Bonus],0)

This works fine if the total in [35% Down Bonus]![Total 35% DN Bonus] has a
value. But when it is equal to or greater than .35 and has a zero value, I
just get blank results.

Some one suggested a nested IIf statement and I have tried several that
don't work at all.

Does anyone have any suggestions on how to write this?
 
Post the SQL for the two queries.

Xjcinhoustonx said:
I have a table that has the items we will pay a bonus on if the downpayment
is >35% but less that 100% of the total sale ( Table A). I have another
table that we enter the items sold (Table B). I have a query that calculated
the bonus on the items that qualify. That is the total I want it to o get.
I think that my problem is stemming from the total on the the other query
being zero.

KARL DEWEY said:
Please explain to me how you can it have zero value and be equal to or
greater than .35?


Xjcinhoustonx said:
No this did not work, It just returned all blanks.

:

But when it is equal to or greater than .35 and has a zero value, I just
get blank results.
This does not make sense. How can it have zero value and be equal to or
greater than .35?

Maybe you need this --
35 DN Bonus: IIf([Dnpmt Perc Of Total]>=0.35 And [Dnpmt Perc Of
Total]<1,[35% Down Bonus]![Total 35% DN Bonus],0) Or Is Null


:

I have a query that has the following statement

35 DN Bonus: IIf([Dnpmt Perc Of Total]>=0.35 And [Dnpmt Perc Of
Total]<1,[35% Down Bonus]![Total 35% DN Bonus],0)

This works fine if the total in [35% Down Bonus]![Total 35% DN Bonus] has a
value. But when it is equal to or greater than .35 and has a zero value, I
just get blank results.

Some one suggested a nested IIf statement and I have tried several that
don't work at all.

Does anyone have any suggestions on how to write this?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

IIf expression 2
IIF delima-Need Help PLEASE! 2
Multiple Iff Statement 4
nested iif function 4
rank query results 11
IIf statements 5
IIf statement Query 17
Repost-Edit and save query criteria 5

Back
Top