subeshvasu Posted November 25, 2009 Share Posted November 25, 2009 Hi,I have defined a query in jasperserver like below .select eno, ename, doj, sal from employ wheredoj between to_date('$P!{p_start}') and to_date('$P!{p_end}')Report input controls are p_start and p_end as parameters., Now when i run my report I get below exception78 ERROR MultiDataSourceQueryExecuter,http-9080-Processor25:130 - Error executing the report: java.sql.SQLException: ORA-01858: a non-numeric character was found where a numeric was expectedselect eno, ename, doj, sal from employ where doj between to_date('Mon Nov 03 00:00:00 IST 2003') and to_date('Sat Nov 28 00:00:00 IST 2015') Parameters: []Need to know , why my query parameters are getting replaced like above?Pls provide me a solution for this. Post Edited by subeshvasu at 11/25/2009 08:04 Link to comment Share on other sites More sharing options...
englbrechtful Posted November 25, 2009 Share Posted November 25, 2009 What DB application are you running? why do you want to do that such complicated? I would use two parameters $P{START} and $P{END} both java.sql.timestamp type. your sql query would look like this then : select eno, ename, doj, sal from employ wheredoj between $P{START} and $P{END} 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