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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to make two groups when there are three values

Status
Not open for further replies.

JonAtHQ

Technical User
Jun 16, 2005
45
US
Hello,

We have employee records with a checkmark as a field to indicate whether someone works from home or not. The records have been imported from another database, so the values for the checkmark are "1", "0" or "NULL".

How do I create a report that produces only two groups? I would like to show the people who work at home (1) together, and the people who do not work at home in another group (0 or NULL).

(Crystal XI)

Thanks.
 
if isnull({table.chkmark}) or
{table.chkmark} = 0 then "NotAtHome" else
if {table.chkmark} = 1 then
"AtHome"

If you mean there is a literal string result "NULL" and if the field is in fact a string, then change the formula to:

if {table.chkmark} in ["Null", "0"] then
"NotAtHome" else
if {table.chkmark} = "1" then
"AtHome"

-LB
 
Perfect. Your first answered worked. Thanks much!

I know this was a rather simple syntax question, but we're business users here using a COTS package, left to customize reports ourselves. So, we try this for a few hours ourselves, then give up, finally posting to Tek-Tips.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top