Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Crystal 10 Formula help needed

Status
Not open for further replies.

HookEmHorns

Programmer
Dec 17, 2009
27
0
0
US
My client has asked me to edit a report by adding in:

“200% - 250%” and “250% and over”. I am uncertain how to edit this. Any suggestions?

Current Formula called in the report:

Code:
If RTRIM({ado.Income}) < '101' then '1. 0% - 100% of Poverty' else
    if RTRIM({ado.Income}) > '101' and 
        RTRIM({ado.Income}) <'151' then '2. 101% - 150% of Poverty' else
    if RTRIM({ado.Income}) > '150' and 
        RTRIM({ado.Income}) <'201' then '3. 151% - 200% of Poverty' else
    if RTRIM({ado.Income}) > '200' AND RTRIM({ado.Income}) <> 'Unknown' then '4. Over 200% of Poverty' else
    '5. Unknown'
 
Can't you just carry out the current logic?

If RTRIM({ado.Income}) < '101' then
'1. 0% - 100% of Poverty' else
if RTRIM({ado.Income}) > '100' and
RTRIM({ado.Income}) <'151' then
'2. 101% - 150% of Poverty' else
if RTRIM({ado.Income}) > '150' and
RTRIM({ado.Income}) <'201' then
'3. 151% - 200% of Poverty' else
if RTRIM({ado.Income}) > '200' AND
RTRIM({ado.Income}) <'251' then
'4. 201% - 250% of Poverty' else
if RTRIM({ado.Income}) > '250' AND
RTRIM({ado.Income}) <> 'Unknown' then
'5. Over 250% of Poverty' else
'6. Unknown'

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top