Jump to content
Changes to the Jaspersoft community edition download ×

Report Query problem


bporter

Recommended Posts

Hi all,

 

 

Assume that I have an SQL statement such as:

 

Select type from user where type = $P{typeParam}

 

 

As long as typeParam has a value, it works fine. But what if the user wants to see all the records in user table... In this case typeParam value will be null (and there is no default value assigned to typeParam).

 

 

There are some "workarounds" like passing the where clause (or even passing the whole SQL) from the application side, but it lowers the usability of iReport... Any idea?

Link to comment
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Hi bporter,

 

How did you manage to pass a parameter with a null value?

 

I encounter

"Please enter a default value for paramter <paramname>"

 

I am trying to search for an ireport equivalent behaviour for the JDBC's preparedStatement.setNull()

Link to comment
Share on other sites

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...