![]() | |
![]() |
| | Thread Tools | Search this Thread | Display Modes |
#1
| |||
| |||
|
|
I have a report where I am trying to return the number of females and males above or below a certain age. I have no prolem with getting totals for males and females. I have an unbound text box woth the foloowing source: =Count(IIf([Age]>="18",0) And ([Sex]="Female",0)) This returns an error. Any ides??? Thx, -Orv =sum(IIF([age] >="18" AND [SEX]="Female",1,0)) |
#2
| |||
| |||
|
#3
| |||
| |||
|
|
"Orv" <pcbidderathotmail.com> wrote in news:jtudnU_ILrHnrFXbnZ2dnUVZ_h-vnZ2d (AT) comcast (DOT) com: I have a report where I am trying to return the number of females and males above or below a certain age. I have no prolem with getting totals for males and females. I have an unbound text box woth the foloowing source: =Count(IIf([Age]>="18",0) And ([Sex]="Female",0)) This returns an error. Any ides??? Thx, -Orv =sum(IIF([age] >="18" AND [SEX]="Female",1,0)) Did you define age as a text type? If it's a number, delete the quotes around the 18. -- Bob Quintal PA is y I've altered my email address. -- Posted via a free Usenet account from http://www.teranews.com Thanks. I think I got it |
#4
| |||
| |||
|
|
"Bob Quintal" <rquintal (AT) sPAmpatico (DOT) ca> wrote in message news:Xns999159CBAFA42BQuintal (AT) 66 (DOT) 150.105.47... "Orv" <pcbidderathotmail.com> wrote in news:jtudnU_ILrHnrFXbnZ2dnUVZ_h-vnZ2d (AT) comcast (DOT) com: I have a report where I am trying to return the number of females and males above or below a certain age. I have no prolem with getting totals for males and females. I have an unbound text box woth the foloowing source: =Count(IIf([Age]>="18",0) And ([Sex]="Female",0)) This returns an error. Any ides??? Thx, -Orv =sum(IIF([age] >="18" AND [SEX]="Female",1,0)) Did you define age as a text type? If it's a number, delete the quotes around the 18. -- Bob Quintal PA is y I've altered my email address. -- Posted via a free Usenet account from http://www.teranews.com Thanks. I think I got it =Count(IIf([Sex]="Female" And ([Age])>="18",0)) Orv |
#5
| |||
| |||
|
|
"Orv" <pcbidderathotmail.com> wrote in message news:47WdnRmtfvLoo1XbnZ2dnUVZ_vihnZ2d (AT) comcast (DOT) com... "Bob Quintal" <rquintal (AT) sPAmpatico (DOT) ca> wrote in message news:Xns999159CBAFA42BQuintal (AT) 66 (DOT) 150.105.47... "Orv" <pcbidderathotmail.com> wrote in news:jtudnU_ILrHnrFXbnZ2dnUVZ_h-vnZ2d (AT) comcast (DOT) com: I have a report where I am trying to return the number of females and males above or below a certain age. I have no prolem with getting totals for males and females. I have an unbound text box woth the foloowing source: =Count(IIf([Age]>="18",0) And ([Sex]="Female",0)) This returns an error. Any ides??? Thx, -Orv =sum(IIF([age] >="18" AND [SEX]="Female",1,0)) Did you define age as a text type? If it's a number, delete the quotes around the 18. -- Bob Quintal PA is y I've altered my email address. -- Posted via a free Usenet account from http://www.teranews.com Thanks. I think I got it =Count(IIf([Sex]="Female" And ([Age])>="18",0)) Orv OK, Now that I got it to return all the females older than 18. Can I throw an "And" in the iff statement to only return a certain race? like this: =Count(IIf([Sex]="Female" And ([Age])>="18",0 And ([Race])="White")) or do I need a different expression altogether? Not quite. =Count(IIf([Sex]="Female" And ([Age])>="18" And ([Race])="White",0 )) |
#6
| |||
| |||
|
|
"Orv" <pcbidderathotmail.com> wrote in news:u8KdnaWhRrtDfVXbnZ2dnUVZ_gKdnZ2d (AT) comcast (DOT) com: "Orv" <pcbidderathotmail.com> wrote in message news:47WdnRmtfvLoo1XbnZ2dnUVZ_vihnZ2d (AT) comcast (DOT) com... "Bob Quintal" <rquintal (AT) sPAmpatico (DOT) ca> wrote in message news:Xns999159CBAFA42BQuintal (AT) 66 (DOT) 150.105.47... "Orv" <pcbidderathotmail.com> wrote in news:jtudnU_ILrHnrFXbnZ2dnUVZ_h-vnZ2d (AT) comcast (DOT) com: I have a report where I am trying to return the number of females and males above or below a certain age. I have no prolem with getting totals for males and females. I have an unbound text box woth the foloowing source: =Count(IIf([Age]>="18",0) And ([Sex]="Female",0)) This returns an error. Any ides??? Thx, -Orv =sum(IIF([age] >="18" AND [SEX]="Female",1,0)) Did you define age as a text type? If it's a number, delete the quotes around the 18. -- Bob Quintal PA is y I've altered my email address. -- Posted via a free Usenet account from http://www.teranews.com Thanks. I think I got it =Count(IIf([Sex]="Female" And ([Age])>="18",0)) Orv OK, Now that I got it to return all the females older than 18. Can I throw an "And" in the iff statement to only return a certain race? like this: =Count(IIf([Sex]="Female" And ([Age])>="18",0 And ([Race])="White")) or do I need a different expression altogether? Not quite. =Count(IIf([Sex]="Female" And ([Age])>="18" And ([Race])="White",0 )) -- Bob Quintal PA is y I've altered my email address. -- Posted via a free Usenet account from http://www.teranews.com |
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |