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

vyrush

Members
  • Posts

    2
  • Joined

  • Last visited

vyrush's Achievements

Newbie

Newbie (1/14)

  • Week One Done
  • One Month Later
  • One Year In
  • First Post Rare
  • Conversation Starter Rare

Recent Badges

0

Reputation

  1. I am passing a text type field from a php form to query the jrxml file.. but the problem is when i pass a value which is not a integer type, i get errors.. the name of the parameter in ireport is P and the parameter class is java.lang.String so i passing a variable like : CODE //THE QUERY IN IREPORT select * from agents where agents.name = $P{p} ------------------------------------ $xml = simplexml_load_file("test.jrxml"); $p=$_GET['p']; $PHPJasperXML = new PHPJasperXML(); $PHPJasperXML->debugsql=false; $PHPJasperXML->arrayParameter=array("p"=>$p); $PHPJasperXML->xml_dismantle($xml); so when even i pass a string, i get errors, but when i run the report within the ireport preview, it works fine. but if i change the query to something which retrieves a int type row then it works fine with the above PHP code.. so please help someone... coz i need to view a report based on a select of user name from a PHP page..
  2. I am passing a text type field from a php form to query the jrxml file.. but the problem is when i pass a value which is not a integer type, i get errors.. the name of the parameter in ireport is P and the parameter class is java.lang.String so i passing a variable like : CODE //THE QUERY IN IREPORT select * from agents where agents.name = $P{p} ------------------------------------ $xml = simplexml_load_file("test.jrxml"); $p=$_GET['p']; $PHPJasperXML = new PHPJasperXML(); $PHPJasperXML->debugsql=false; $PHPJasperXML->arrayParameter=array("p"=>$p); $PHPJasperXML->xml_dismantle($xml); so when even i pass a string, i get errors, but when i run the report within the ireport preview, it works fine. but if i change the query to something which retrieves a int type row then it works fine with the above PHP code.. so please help someone... coz i need to view a report based on a select of user name from a PHP page..
×
×
  • Create New...