pavithram Posted October 18, 2012 Share Posted October 18, 2012 Im tring to filter records by giving IN cluase in the select statement. Report main query is given below: select v.br_code,v.br_name,v.br_admin_unitfrom branch vwhere br_admin_unit=$X{IN, br_admin_unit, br_admin_unit} I have define the input control where user can select the branch admin unit. parameter name is defined as 'br_admin_unit' java.util.Collection.though the report is generated records are not filtered in the report. pls provide some solution. Link to comment Share on other sites More sharing options...
ajinkya_c Posted October 18, 2012 Share Posted October 18, 2012 Try this Query ------------------ select v.br_code,v.br_name,v.br_admin_unit from branch v where $X{IN, br_admin_unit, br_admin_unit} Link to comment Share on other sites More sharing options...
Solution marianol Posted October 18, 2012 Solution Share Posted October 18, 2012 ajinkya_c has a good point use the query he added in the comment.The $X{..} funtion has to be used as:$X{IN, field_name, parameter_name} Jasper will take care of creating the correct SQL syntax. Link to comment Share on other sites More sharing options...
pavithram Posted October 19, 2012 Author Share Posted October 19, 2012 Yes Its working. Thanks for the support. Link to comment Share on other sites More sharing options...
marianol Posted October 19, 2012 Share Posted October 19, 2012 You are welcome. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now