K
Ken
I am developing a query that have two fields as follows:
LTVrtgHO: IIf([PropType]='HO',IIf([ImpliedLTV]>0.7,1,IIf
([ImpliedLTV] Between 0.65011 And 0.6999,2,IIf
([ImpliedLTV] Between 0.6001 And 0.65,3,IIf([ImpliedLTV]
<0.6,4,'N/A')))),'N/A')
and:
LTVrtg: IIf([PropType]='HO',[LTVrtgHO],IIf([ImpliedLTV]
<=0.7,4,1)))))
When I run the query, I get the error message: "Query Too
Complex." I cannot find anything on this error message in
either MS Access Help or a search on the the MS Knowledge
Base.
I realize the component causing the problem is the
[LTVrtgHO] portion of the LTVrtg expression. The reason I
know this is that I can substitute a "1" for the
[LTVrtgHO] variable in the expression and it works without
an error message. Why would referring to another field
cause the error message? I am also aware that you can't
have more than seven nested IF..THEN statements in an
expression. Would making reference to an expression that
had nested IF..THEN statements count in the seven? If so,
how could I get around this? I don't know VBA yet.
Thanks in advance!
Ken
LTVrtgHO: IIf([PropType]='HO',IIf([ImpliedLTV]>0.7,1,IIf
([ImpliedLTV] Between 0.65011 And 0.6999,2,IIf
([ImpliedLTV] Between 0.6001 And 0.65,3,IIf([ImpliedLTV]
<0.6,4,'N/A')))),'N/A')
and:
LTVrtg: IIf([PropType]='HO',[LTVrtgHO],IIf([ImpliedLTV]
([ImpliedLTV] Between 0.7001 And 0.75,3,IIf([ImpliedLTV]=0.8,1,IIf([ImpliedLTV] Between 0.75001 And 0.7999,2,IIf
<=0.7,4,1)))))
When I run the query, I get the error message: "Query Too
Complex." I cannot find anything on this error message in
either MS Access Help or a search on the the MS Knowledge
Base.
I realize the component causing the problem is the
[LTVrtgHO] portion of the LTVrtg expression. The reason I
know this is that I can substitute a "1" for the
[LTVrtgHO] variable in the expression and it works without
an error message. Why would referring to another field
cause the error message? I am also aware that you can't
have more than seven nested IF..THEN statements in an
expression. Would making reference to an expression that
had nested IF..THEN statements count in the seven? If so,
how could I get around this? I don't know VBA yet.
Thanks in advance!
Ken