Jump to content
We've recently updated our Privacy Statement, available here ×

How to evaluate a blank string "" in an expression


dprogrammer

Recommended Posts

I have a parameter1 that may be blank in some cases. So I have another parameter2 which wants to check if the parameter1 is blank, then it will say 'All' else parameter1. I have tried following but its not evaluating correctly.

$P{parameter1}.equals("")? 'ALL':$P{parameter1}

$P{parameter1}==""? 'ALL':$P{parameter1}

$P{parameter1}==null? 'ALL':$P{parameter1}

Any ideas please?

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...