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

IsNull in Record Selection formula

Status
Not open for further replies.

sepia

Programmer
May 18, 2001
26
US
Hi all. I'm trying to format a field on a report using the IsNull function. Unfortunately, I'm getting the following error: "The result of selection formula must be a boolean".

Here's the code:

If IsNull({rpMIGroupAuthDetail;1.Service_SubCategory_Desc})
THEN {rpMIGroupAuthDetail;1.Service_Category_Desc}
ELSE {rpMIGroupAuthDetail;1.Service_SubCategory_Desc}

Can anyone see the error of my ways?
 
Why does the title say a record selection formula, and the description say that you're formatting a field?

I think that you need to state technical information for a while until you learn technical jargon and how Crystal works:

Successful posts tend to include:

Crystal version
Database/connectivity usedf
Example data
Expected output

If you take your approach you'll almost assuredly create blogs as we try to figure out what you think tehcnical terms mean and what you are trying to do.

A record selection filters rows, it doesn't selectively decide which fields to return.

Formatting a field means changing it's attributes, such as color, font,. etc.

I'll take a stab that what you're trying to do is create a formula (I'd provide the exact steps for doing so but you didn't provide what software you're using) that conditionally displays a value based on whether a field is null.

Your syntax is fine, just right click Formulas in the data explorer (or whatever it's called in your version) and select Insert New, then use your code (your code was PERFECT, by the way!!!)

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top