jasper-reports

How to use multiple xpath datasets on XML datasource using PHP Jasper?

不羁的心 提交于 2020-07-08 00:34:43
问题 I have designed a report in Jasper Studio that use XML as datasource and two XPATH datasets. I am able to generate the report and the data is filled from the first dataset (/data/invoice), but the second dataset (/data/invoice_items/row) is not found and returns null. How can I add a second xpath to the php script for 'xml_xpath' => '/data/invoice_items/row' This is my XML data: <?xml version="1.0" encoding="utf-8"?> <data> <invoice> <ID_Invoice>54654</ID_Invoice> <Invoice_Code>FCS</Invoice

How to use multiple xpath datasets on XML datasource using PHP Jasper?

醉酒当歌 提交于 2020-07-08 00:32:11
问题 I have designed a report in Jasper Studio that use XML as datasource and two XPATH datasets. I am able to generate the report and the data is filled from the first dataset (/data/invoice), but the second dataset (/data/invoice_items/row) is not found and returns null. How can I add a second xpath to the php script for 'xml_xpath' => '/data/invoice_items/row' This is my XML data: <?xml version="1.0" encoding="utf-8"?> <data> <invoice> <ID_Invoice>54654</ID_Invoice> <Invoice_Code>FCS</Invoice

How to use multiple xpath datasets on XML datasource using PHP Jasper?

人走茶凉 提交于 2020-07-08 00:31:23
问题 I have designed a report in Jasper Studio that use XML as datasource and two XPATH datasets. I am able to generate the report and the data is filled from the first dataset (/data/invoice), but the second dataset (/data/invoice_items/row) is not found and returns null. How can I add a second xpath to the php script for 'xml_xpath' => '/data/invoice_items/row' This is my XML data: <?xml version="1.0" encoding="utf-8"?> <data> <invoice> <ID_Invoice>54654</ID_Invoice> <Invoice_Code>FCS</Invoice

Jasper Reports Excel output

给你一囗甜甜゛ 提交于 2020-06-24 07:39:48
问题 I need to generate a report in Excel format using Jasperreports. I am using iReports 3.7.0 The reports gets generated with no issues except the size of empty cells. Can somebody please tell how to avoid the highlighted cell being enlarged. Also the normal cells are also a little larger than their content. 回答1: Also,I would say stick to basics when you need to export Japser to XLS. I mean no graphics, and more. The above solution is good for generating XLS from iReport. If you would like to

JRDataset property CSV file

若如初见. 提交于 2020-04-30 06:29:40
问题 I have a build up a report with a .CSV input file as DataAdapter. After that I needeed a table to put some data into a it and a linked dataset. The problem is: if I leave blank the section "Default Data Adapter" in my Dataset1, no data will be displayed. In fact, to fix this report I had to export my DataAdapter as myDataAdapter.xml and then put this file in the section " Default Data Adapter " of my Dataset1 (as shown in the attached picture). Working with database I have never set up this

JRDataset property CSV file

China☆狼群 提交于 2020-04-30 06:28:06
问题 I have a build up a report with a .CSV input file as DataAdapter. After that I needeed a table to put some data into a it and a linked dataset. The problem is: if I leave blank the section "Default Data Adapter" in my Dataset1, no data will be displayed. In fact, to fix this report I had to export my DataAdapter as myDataAdapter.xml and then put this file in the section " Default Data Adapter " of my Dataset1 (as shown in the attached picture). Working with database I have never set up this

Return value from subdataset in iReport

南楼画角 提交于 2020-04-11 17:04:33
问题 I know that it is possible to get a return value from a subreport to the main report in iReport. Also there are subdatasets which can also have an own SQL query like a subreport. As I understand a subdataset can only be used with list, charts etc., but I don't know how to access the subdataset fields, variables and parameters in the main dataset/report. Is it also possible to get a return value from a subdataset? If not, how is it possible to access values from the subdataset? 回答1: It is

Passing an entire sql query as a parameter in jasper reports

只谈情不闲聊 提交于 2020-04-08 18:06:36
问题 I want to pass an entire sql query as a parameter into a jasper report. I tried using $P{QUERY}, but it gave me a mysql syntax error exception. And I want it to be passed during run time. Does anyone know how to do it? Example code: try { Map<String, Object> map = new HashMap<>(); Connection conn = DatabaseConnection.getInstance().getConnection(); map.put("QUERY", "Select u.name, u.status from user_info u where u.user_name = 'Thanuj'"); JasperReport report = JasperCompileManager.compileReport

Passing an entire sql query as a parameter in jasper reports

一曲冷凌霜 提交于 2020-04-08 18:04:20
问题 I want to pass an entire sql query as a parameter into a jasper report. I tried using $P{QUERY}, but it gave me a mysql syntax error exception. And I want it to be passed during run time. Does anyone know how to do it? Example code: try { Map<String, Object> map = new HashMap<>(); Connection conn = DatabaseConnection.getInstance().getConnection(); map.put("QUERY", "Select u.name, u.status from user_info u where u.user_name = 'Thanuj'"); JasperReport report = JasperCompileManager.compileReport

How to insert a page break in JasperReport

我们两清 提交于 2020-04-07 17:42:09
问题 I have a JasperReports template, with a filled detail band. If I run the report, I have a page count of 27 (27 detail rows) I want that detail row number 12 begins with a new page, so I have to insert a pagebreak after pagecount 11. But I cannot find the element "pagebreak" - What is it called in Jasper? The 2nd question : Is it also possible to modify the format (font, size,....) of each detail-row? For example: pagecount 1 - detail row is printed in sansSerif font size 10, pagecount 2 -