A boolean is required here error

What is wrong with this statement.  I have tried multiple ways to get it right

I have a selection statement that gives me the correct data that I want.  I want to use this formula to check for a null value or a particular empty field and insert "operator" when the conditions are true.

Also where do I stick the formula.  I have tried inside the formula workshop and the selection formula?

If isNull ({Journal.person1fullname}) or trim({Journal.person1fullname} = "") and {Journal.status1codeidx} = 22001  Then "Operator"  else {Journal.person1fullname}
Thanks_for_your_helpAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

peter57rCommented:
I'm assuming you mean..

If (isNull ({Journal.person1fullname}) or trim({Journal.person1fullname} = ""))
and {Journal.status1codeidx} = 22001  Then
"Operator"  
else
{Journal.person1fullname}

You should create a formula field for this.  You then use the formula field in your report, not the fullname database field.
Thanks_for_your_helpAuthor Commented:


I get a "A string is required here" error

trim({Journal.person1fullname}

zephyr_hex (Megan)DeveloperCommented:
trim() function takes an argument, which means it's bounded by parenthesis

trim({Journal.person1fullname} = "")  is not correct

trim({field}) is correct
then add your comparison

trim({field}) = ""

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
mlmccCommented:
o consolidate the suggestions above (give them the points if this works)

If (isNull ({Journal.person1fullname}) or trim({Journal.person1fullname}) = "") and {Journal.status1codeidx} = 22001  Then "Operator"  else {Journal.person1fullname}

What value do you want if the status isn't 22001?

mlmcc
Thanks_for_your_helpAuthor Commented:
Thanks, taking both your comments, I finally got it to work.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
DB Reporting Tools

From novice to tech pro — start learning today.