Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » BIRT » How to do Pagination in BIRT(Hi How to do Pagination in BIRT)
How to do Pagination in BIRT [message #636454] Mon, 01 November 2010 12:50 Go to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
Hi..
Am new to BIRT...
How to do Pagination in BIRT
Re: How to do Pagination in BIRT [message #636495 is a reply to message #636454] Mon, 01 November 2010 15:16 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

You can set page breaks on many of the elements in BIRT. Look at the
Page Break tab in the general properties of elements like tables and
lists. By default the engine will page break automatically based on the
size of the master page. You can also set page break interval which is
used in tables and list to page break after a certain number of rows.

Jason

On 11/1/2010 8:50 AM, R.Murali wrote:
> Hi..
> Am new to BIRT... How to do Pagination in BIRT
Re: How to do Pagination in BIRT [message #636924 is a reply to message #636495] Wed, 03 November 2010 11:43 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
Thank u very much..
Am using a table with 320 rows of data...
Using Page Break Properties i made 20 rows to be displayed in single page.
So that while viewing in Report Viewer i can able to view totally 17 pages onebyone...
Now i want to add an aggregate function (SUM) which should add values of the coulmn(column Name:marks) for everypage and have to print at the end of everypages and also I have to print the grand total of all the 17 pages(marks field) and print in last page.....Pls help me regarding this...
Re: How to do Pagination in BIRT [message #636925 is a reply to message #636495] Wed, 03 November 2010 11:49 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
Sir
Until now i know how to design a simple report....
Pls suggest me how to program the report ...ie how to access or create report by java programming....any materials regarding this..
Thank u sir
Re: How to do Pagination in BIRT [message #636926 is a reply to message #636495] Wed, 03 November 2010 11:50 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
Sir,
suggest me the basic materials for javascipting in BIRT
Re: How to do Pagination in BIRT [message #636991 is a reply to message #636924] Wed, 03 November 2010 16:42 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Do you have grouping on the report or do you just want a separate sum
per page?

Jason

On 11/3/2010 7:43 AM, R.Murali wrote:
> Thank u very much..
> Am using a table with 320 rows of data...
> Using Page Break Properties i made 20 rows to be displayed in single page.
> So that while viewing in Report Viewer i can able to view totally 17
> pages onebyone...
> Now i want to add an aggregate function (SUM) which should add values of
> the coulmn(column Name:marks) for everypage and have to print at the end
> of everypages and also I have to print the grand total of all the 17
> pages(marks field) and print in last page.....Pls help me regarding this...
Re: How to do Pagination in BIRT [message #636992 is a reply to message #636925] Wed, 03 November 2010 16:48 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

To create reports with Java you need to use the DE API. To run reports
with Java use the RE API There are webinars on these here:
REAPI
http://www.birt-exchange.com/be/info/reportengineapi-websem/

DEAPI
http://www.birt-exchange.com/be/info/designengineapi-websem/
You will need to register on Birt-Exchange, but there are a lot of
examples in the devshare so its good to do anyways and its free.


examples here:
http://www.birt-exchange.org/org/devshare/designing-birt-rep orts/409-deapi-examples-from-birt-exchange-webinar/

Jason

On 11/3/2010 7:49 AM, R.Murali wrote:
> Sir
> Until now i know how to design a simple report....
> Pls suggest me how to program the report ...ie how to access or create
> report by java programming....any materials regarding this.. Thank u sir
Re: How to do Pagination in BIRT [message #636993 is a reply to message #636926] Wed, 03 November 2010 16:49 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Take a look at this:
http://www.eclipse.org/birt/phoenix/deploy/reportScripting.p hp

Jason

On 11/3/2010 7:50 AM, R.Murali wrote:
> Sir,
> suggest me the basic materials for javascipting in BIRT
Re: How to do Pagination in BIRT [message #637910 is a reply to message #636993] Tue, 09 November 2010 10:24 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
Thank you very much sir
Re: How to do Pagination in BIRT [message #637922 is a reply to message #636991] Tue, 09 November 2010 11:17 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
i need separate sum per page
Re: How to do Pagination in BIRT [message #637989 is a reply to message #637922] Tue, 09 November 2010 14:56 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Take a look at this example that uses a page variable and page scripts
to do this.

Jason


<?xml version="1.0" encoding="UTF-8"?>
<report xmlns="http://www.eclipse.org/birt/2005/design" version="3.2.21"
id="1">
<property name="createdBy">Eclipse BIRT Designer Version
2.6.0.v20100531 Build &lt;2.6.0.v20100609-1613></property>
<property name="units">in</property>
<property name="iconFile">/templates/blank_report.gif</property>
<property name="bidiLayoutOrientation">ltr</property>
<property name="imageDPI">96</property>
<data-sources>
<oda-data-source
extensionID="org.eclipse.birt.report.data.oda.jdbc" name="Data Source"
id="7">
<property
name="odaDriverClass">org.eclipse.birt.report.data.oda.sampledb.Driver </property>
<property name="odaURL">jdbc:classicmodels:sampledb</property>
<property name="odaUser">ClassicModels</property>
<property name="OdaConnProfileName"></property>
</oda-data-source>
</data-sources>
<data-sets>
<oda-data-set
extensionID="org.eclipse.birt.report.data.oda.jdbc.JdbcSelectDataSet "
name="Data Set" id="8">
<list-property name="columnHints">
<structure>
<property name="columnName">ORDERNUMBER</property>
<text-property
name="displayName">ORDERNUMBER</text-property>
</structure>
<structure>
<property name="columnName">PRODUCTCODE</property>
<text-property
name="displayName">PRODUCTCODE</text-property>
</structure>
<structure>
<property name="columnName">QUANTITYORDERED</property>
<text-property
name="displayName">QUANTITYORDERED</text-property>
</structure>
<structure>
<property name="columnName">PRICEEACH</property>
<text-property
name="displayName">PRICEEACH</text-property>
</structure>
<structure>
<property name="columnName">ORDERLINENUMBER</property>
<text-property
name="displayName">ORDERLINENUMBER</text-property>
</structure>
</list-property>
<structure name="cachedMetaData">
<list-property name="resultSet">
<structure>
<property name="position">1</property>
<property name="name">ORDERNUMBER</property>
<property name="dataType">integer</property>
</structure>
<structure>
<property name="position">2</property>
<property name="name">PRODUCTCODE</property>
<property name="dataType">string</property>
</structure>
<structure>
<property name="position">3</property>
<property name="name">QUANTITYORDERED</property>
<property name="dataType">integer</property>
</structure>
<structure>
<property name="position">4</property>
<property name="name">PRICEEACH</property>
<property name="dataType">float</property>
</structure>
<structure>
<property name="position">5</property>
<property name="name">ORDERLINENUMBER</property>
<property name="dataType">integer</property>
</structure>
</list-property>
</structure>
<property name="dataSource">Data Source</property>
<list-property name="resultSet">
<structure>
<property name="position">1</property>
<property name="name">ORDERNUMBER</property>
<property name="nativeName">ORDERNUMBER</property>
<property name="dataType">integer</property>
<property name="nativeDataType">4</property>
</structure>
<structure>
<property name="position">2</property>
<property name="name">PRODUCTCODE</property>
<property name="nativeName">PRODUCTCODE</property>
<property name="dataType">string</property>
<property name="nativeDataType">12</property>
</structure>
<structure>
<property name="position">3</property>
<property name="name">QUANTITYORDERED</property>
<property name="nativeName">QUANTITYORDERED</property>
<property name="dataType">integer</property>
<property name="nativeDataType">4</property>
</structure>
<structure>
<property name="position">4</property>
<property name="name">PRICEEACH</property>
<property name="nativeName">PRICEEACH</property>
<property name="dataType">float</property>
<property name="nativeDataType">8</property>
</structure>
<structure>
<property name="position">5</property>
<property name="name">ORDERLINENUMBER</property>
<property name="nativeName">ORDERLINENUMBER</property>
<property name="dataType">integer</property>
<property name="nativeDataType">5</property>
</structure>
</list-property>
<xml-property name="queryText"><![CDATA[select *
from orderdetails]]></xml-property>
<xml-property name="designerValues"><![CDATA[<?xml
version="1.0" encoding="UTF-8"?>
<model:DesignValues
xmlns:design="http://www.eclipse.org/datatools/connectivity/oda/design"
xmlns:model="http://www.eclipse.org/birt/report/model/adapter/odaModel">
<Version>1.0</Version>
<design:ResultSets derivedMetaData="true">
<design:resultSetDefinitions>
<design:resultSetColumns>
<design:resultColumnDefinitions>
<design:attributes>
<design:name>ORDERNUMBER</design:name>
<design:position>1</design:position>
<design:nativeDataTypeCode>4</design:nativeDataTypeCode>
<design:precision>10</design:precision>
<design:scale>0</design:scale>
<design:nullability>Nullable</design:nullability>
<design:uiHints>
<design:displayName>ORDERNUMBER</design:displayName>
</design:uiHints>
</design:attributes>
<design:usageHints>
<design:label>ORDERNUMBER</design:label>
<design:formattingHints>
<design:displaySize>11</design:displaySize>
</design:formattingHints>
</design:usageHints>
</design:resultColumnDefinitions>
<design:resultColumnDefinitions>
<design:attributes>
<design:name>PRODUCTCODE</design:name>
<design:position>2</design:position>
<design:nativeDataTypeCode>12</design:nativeDataTypeCode>
<design:precision>15</design:precision>
<design:scale>0</design:scale>
<design:nullability>Nullable</design:nullability>
<design:uiHints>
<design:displayName>PRODUCTCODE</design:displayName>
</design:uiHints>
</design:attributes>
<design:usageHints>
<design:label>PRODUCTCODE</design:label>
<design:formattingHints>
<design:displaySize>15</design:displaySize>
</design:formattingHints>
</design:usageHints>
</design:resultColumnDefinitions>
<design:resultColumnDefinitions>
<design:attributes>
<design:name>QUANTITYORDERED</design:name>
<design:position>3</design:position>
<design:nativeDataTypeCode>4</design:nativeDataTypeCode>
<design:precision>10</design:precision>
<design:scale>0</design:scale>
<design:nullability>Nullable</design:nullability>
<design:uiHints>
<design:displayName>QUANTITYORDERED</design:displayName>
</design:uiHints>
</design:attributes>
<design:usageHints>
<design:label>QUANTITYORDERED</design:label>
<design:formattingHints>
<design:displaySize>11</design:displaySize>
</design:formattingHints>
</design:usageHints>
</design:resultColumnDefinitions>
<design:resultColumnDefinitions>
<design:attributes>
<design:name>PRICEEACH</design:name>
<design:position>4</design:position>
<design:nativeDataTypeCode>8</design:nativeDataTypeCode>
<design:precision>15</design:precision>
<design:scale>0</design:scale>
<design:nullability>Nullable</design:nullability>
<design:uiHints>
<design:displayName>PRICEEACH</design:displayName>
</design:uiHints>
</design:attributes>
<design:usageHints>
<design:label>PRICEEACH</design:label>
<design:formattingHints>
<design:displaySize>22</design:displaySize>
</design:formattingHints>
</design:usageHints>
</design:resultColumnDefinitions>
<design:resultColumnDefinitions>
<design:attributes>
<design:name>ORDERLINENUMBER</design:name>
<design:position>5</design:position>
<design:nativeDataTypeCode>5</design:nativeDataTypeCode>
<design:precision>5</design:precision>
<design:scale>0</design:scale>
<design:nullability>Nullable</design:nullability>
<design:uiHints>
<design:displayName>ORDERLINENUMBER</design:displayName>
</design:uiHints>
</design:attributes>
<design:usageHints>
<design:label>ORDERLINENUMBER</design:label>
<design:formattingHints>
<design:displaySize>6</design:displaySize>
</design:formattingHints>
</design:usageHints>
</design:resultColumnDefinitions>
</design:resultSetColumns>
<design:criteria/>
</design:resultSetDefinitions>
</design:ResultSets>
</model:DesignValues>]]></xml-property>
</oda-data-set>
</data-sets>
<styles>
<style name="report" id="4">
<property name="fontFamily">sans-serif</property>
<property name="fontSize">10pt</property>
</style>
<style name="crosstab-cell" id="5">
<property name="borderBottomColor">#CCCCCC</property>
<property name="borderBottomStyle">solid</property>
<property name="borderBottomWidth">1pt</property>
<property name="borderLeftColor">#CCCCCC</property>
<property name="borderLeftStyle">solid</property>
<property name="borderLeftWidth">1pt</property>
<property name="borderRightColor">#CCCCCC</property>
<property name="borderRightStyle">solid</property>
<property name="borderRightWidth">1pt</property>
<property name="borderTopColor">#CCCCCC</property>
<property name="borderTopStyle">solid</property>
<property name="borderTopWidth">1pt</property>
</style>
<style name="crosstab" id="6">
<property name="borderBottomColor">#CCCCCC</property>
<property name="borderBottomStyle">solid</property>
<property name="borderBottomWidth">1pt</property>
<property name="borderLeftColor">#CCCCCC</property>
<property name="borderLeftStyle">solid</property>
<property name="borderLeftWidth">1pt</property>
<property name="borderRightColor">#CCCCCC</property>
<property name="borderRightStyle">solid</property>
<property name="borderRightWidth">1pt</property>
<property name="borderTopColor">#CCCCCC</property>
<property name="borderTopStyle">solid</property>
<property name="borderTopWidth">1pt</property>
</style>
</styles>
<page-setup>
<simple-master-page name="Simple MasterPage" id="2">
<method name="onPageEnd"><![CDATA[var qtys =
this.getInstancesByElementName("qtyelement");
var tmp=0;
if( qtys != null ){
for( var i=0; i< qtys.length; i++ ){
//Instance of DataItemInstance
var qty = qtys[i];
tmp+=parseInt(qty.getValue());
}

}
reportContext.setPageVariable("pageqty",tmp);]]></method>
<page-header>
<auto-text id="44">
<property name="backgroundColor">#FF8080</property>
<property name="type">page-variable</property>
<property name="pageVariable">pageqty</property>
</auto-text>
</page-header>
<page-footer>
<text id="3">
<property name="contentType">html</property>
<text-property
name="content"><![CDATA[<value-of>new Date()</value-of>]]></text-property>
</text>
</page-footer>
</simple-master-page>
</page-setup>
<body>
<table id="9">
<property name="dataSet">Data Set</property>
<list-property name="boundDataColumns">
<structure>
<property name="name">ORDERNUMBER</property>
<text-property
name="displayName">ORDERNUMBER</text-property>
<expression name="expression"
type="javascript">dataSetRow["ORDERNUMBER"]</expression >
<property name="dataType">integer</property>
</structure>
<structure>
<property name="name">PRODUCTCODE</property>
<text-property
name="displayName">PRODUCTCODE</text-property>
<expression name="expression"
type="javascript">dataSetRow["PRODUCTCODE"]</expression >
<property name="dataType">string</property>
</structure>
<structure>
<property name="name">QUANTITYORDERED</property>
<text-property
name="displayName">QUANTITYORDERED</text-property>
<expression name="expression"
type="javascript">dataSetRow["QUANTITYORDERED"]</expression >
<property name="dataType">integer</property>
</structure>
<structure>
<property name="name">PRICEEACH</property>
<text-property
name="displayName">PRICEEACH</text-property>
<expression name="expression"
type="javascript">dataSetRow["PRICEEACH"]</expression>
<property name="dataType">float</property>
</structure>
<structure>
<property name="name">ORDERLINENUMBER</property>
<text-property
name="displayName">ORDERLINENUMBER</text-property>
<expression name="expression"
type="javascript">dataSetRow["ORDERLINENUMBER"]</expression >
<property name="dataType">integer</property>
</structure>
</list-property>
<property name="pageBreakInterval">4</property>
<column id="38"/>
<column id="39"/>
<column id="40"/>
<column id="41"/>
<column id="42"/>
<header>
<row id="10">
<cell id="11">
<label id="12">
<text-property
name="text">ORDERNUMBER</text-property>
</label>
</cell>
<cell id="13">
<label id="14">
<text-property
name="text">PRODUCTCODE</text-property>
</label>
</cell>
<cell id="15">
<label id="16">
<text-property
name="text">QUANTITYORDERED</text-property>
</label>
</cell>
<cell id="17">
<label id="18">
<text-property
name="text">PRICEEACH</text-property>
</label>
</cell>
<cell id="19">
<label id="20">
<text-property
name="text">ORDERLINENUMBER</text-property>
</label>
</cell>
</row>
</header>
<detail>
<row id="21">
<cell id="22">
<data id="23">
<property
name="resultSetColumn">ORDERNUMBER</property>
</data>
</cell>
<cell id="24">
<data id="25">
<property
name="resultSetColumn">PRODUCTCODE</property>
</data>
</cell>
<cell id="26">
<data name="qtyelement" id="27">
<property
name="resultSetColumn">QUANTITYORDERED</property>
</data>
</cell>
<cell id="28">
<data id="29">
<property
name="resultSetColumn">PRICEEACH</property>
</data>
</cell>
<cell id="30">
<data id="31">
<property
name="resultSetColumn">ORDERLINENUMBER</property>
</data>
</cell>
</row>
</detail>
<footer>
<row id="32">
<cell id="33"/>
<cell id="34"/>
<cell id="35"/>
<cell id="36"/>
<cell id="37"/>
</row>
</footer>
</table>
</body>
<property name="pageVariables">
<variable-element name="pageqty">
<property name="type">page</property>
</variable-element>
</property>
</report>


On 11/9/2010 6:17 AM, R.Murali wrote:
> i need separate sum per page
Re: How to do Pagination in BIRT [message #638140 is a reply to message #637989] Wed, 10 November 2010 07:50 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
sir
actually for what purpose we are using xml in birt repoting....
whether i have to learn xml for Birt Reporting.....
How to use XML in birt....
Re: How to do Pagination in BIRT [message #638300 is a reply to message #638140] Wed, 10 November 2010 18:07 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

That xml was just a birt report. You can copy it and create a new
report in birt select the xml view and paste the xml from the previous post.

Jason

On 11/10/2010 2:50 AM, R.Murali wrote:
> sir actually for what purpose we are using xml in birt repoting....
> whether i have to learn xml for Birt Reporting.....
> How to use XML in birt....
Re: How to do Pagination in BIRT [message #638416 is a reply to message #638300] Thu, 11 November 2010 09:20 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
yes..Sir i got sum for everypage....
how to get sum of all the pages as grand sum in last page....
Re: How to do Pagination in BIRT [message #638527 is a reply to message #638416] Thu, 11 November 2010 15:03 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

You could just add an aggreation report item to the table footer or use
a report variable in addition to the page variable. I have modified the
example to show both. The blue row rows the aggregation report item and
the orange shows the report variable. The value of the report variable
is set in an oncreate script of the aggregation report item.

Jason

<?xml version="1.0" encoding="UTF-8"?>
<report xmlns="http://www.eclipse.org/birt/2005/design" version="3.2.22"
id="1">
<property name="createdBy">Eclipse BIRT Designer Version
2.6.1.v20100902 Build &lt;2.6.1.v20100915-1750></property>
<property name="units">in</property>
<property name="iconFile">/templates/blank_report.gif</property>
<property name="bidiLayoutOrientation">ltr</property>
<property name="imageDPI">96</property>
<data-sources>
<oda-data-source
extensionID="org.eclipse.birt.report.data.oda.jdbc" name="Data Source"
id="7">
<property
name="odaDriverClass">org.eclipse.birt.report.data.oda.sampledb.Driver </property>
<property name="odaURL">jdbc:classicmodels:sampledb</property>
<property name="odaUser">ClassicModels</property>
<property name="OdaConnProfileName"></property>
</oda-data-source>
</data-sources>
<data-sets>
<oda-data-set
extensionID="org.eclipse.birt.report.data.oda.jdbc.JdbcSelectDataSet "
name="Data Set" id="8">
<list-property name="columnHints">
<structure>
<property name="columnName">ORDERNUMBER</property>
<text-property
name="displayName">ORDERNUMBER</text-property>
</structure>
<structure>
<property name="columnName">PRODUCTCODE</property>
<text-property
name="displayName">PRODUCTCODE</text-property>
</structure>
<structure>
<property name="columnName">QUANTITYORDERED</property>
<text-property
name="displayName">QUANTITYORDERED</text-property>
</structure>
<structure>
<property name="columnName">PRICEEACH</property>
<text-property
name="displayName">PRICEEACH</text-property>
</structure>
<structure>
<property name="columnName">ORDERLINENUMBER</property>
<text-property
name="displayName">ORDERLINENUMBER</text-property>
</structure>
</list-property>
<structure name="cachedMetaData">
<list-property name="resultSet">
<structure>
<property name="position">1</property>
<property name="name">ORDERNUMBER</property>
<property name="dataType">integer</property>
</structure>
<structure>
<property name="position">2</property>
<property name="name">PRODUCTCODE</property>
<property name="dataType">string</property>
</structure>
<structure>
<property name="position">3</property>
<property name="name">QUANTITYORDERED</property>
<property name="dataType">integer</property>
</structure>
<structure>
<property name="position">4</property>
<property name="name">PRICEEACH</property>
<property name="dataType">float</property>
</structure>
<structure>
<property name="position">5</property>
<property name="name">ORDERLINENUMBER</property>
<property name="dataType">integer</property>
</structure>
</list-property>
</structure>
<property name="dataSource">Data Source</property>
<list-property name="resultSet">
<structure>
<property name="position">1</property>
<property name="name">ORDERNUMBER</property>
<property name="nativeName">ORDERNUMBER</property>
<property name="dataType">integer</property>
<property name="nativeDataType">4</property>
</structure>
<structure>
<property name="position">2</property>
<property name="name">PRODUCTCODE</property>
<property name="nativeName">PRODUCTCODE</property>
<property name="dataType">string</property>
<property name="nativeDataType">12</property>
</structure>
<structure>
<property name="position">3</property>
<property name="name">QUANTITYORDERED</property>
<property name="nativeName">QUANTITYORDERED</property>
<property name="dataType">integer</property>
<property name="nativeDataType">4</property>
</structure>
<structure>
<property name="position">4</property>
<property name="name">PRICEEACH</property>
<property name="nativeName">PRICEEACH</property>
<property name="dataType">float</property>
<property name="nativeDataType">8</property>
</structure>
<structure>
<property name="position">5</property>
<property name="name">ORDERLINENUMBER</property>
<property name="nativeName">ORDERLINENUMBER</property>
<property name="dataType">integer</property>
<property name="nativeDataType">5</property>
</structure>
</list-property>
<xml-property name="queryText"><![CDATA[select *
from orderdetails]]></xml-property>
<xml-property name="designerValues"><![CDATA[<?xml
version="1.0" encoding="UTF-8"?>
<model:DesignValues
xmlns:design="http://www.eclipse.org/datatools/connectivity/oda/design"
xmlns:model="http://www.eclipse.org/birt/report/model/adapter/odaModel">
<Version>1.0</Version>
<design:ResultSets derivedMetaData="true">
<design:resultSetDefinitions>
<design:resultSetColumns>
<design:resultColumnDefinitions>
<design:attributes>
<design:name>ORDERNUMBER</design:name>
<design:position>1</design:position>
<design:nativeDataTypeCode>4</design:nativeDataTypeCode>
<design:precision>10</design:precision>
<design:scale>0</design:scale>
<design:nullability>Nullable</design:nullability>
<design:uiHints>
<design:displayName>ORDERNUMBER</design:displayName>
</design:uiHints>
</design:attributes>
<design:usageHints>
<design:label>ORDERNUMBER</design:label>
<design:formattingHints>
<design:displaySize>11</design:displaySize>
</design:formattingHints>
</design:usageHints>
</design:resultColumnDefinitions>
<design:resultColumnDefinitions>
<design:attributes>
<design:name>PRODUCTCODE</design:name>
<design:position>2</design:position>
<design:nativeDataTypeCode>12</design:nativeDataTypeCode>
<design:precision>15</design:precision>
<design:scale>0</design:scale>
<design:nullability>Nullable</design:nullability>
<design:uiHints>
<design:displayName>PRODUCTCODE</design:displayName>
</design:uiHints>
</design:attributes>
<design:usageHints>
<design:label>PRODUCTCODE</design:label>
<design:formattingHints>
<design:displaySize>15</design:displaySize>
</design:formattingHints>
</design:usageHints>
</design:resultColumnDefinitions>
<design:resultColumnDefinitions>
<design:attributes>
<design:name>QUANTITYORDERED</design:name>
<design:position>3</design:position>
<design:nativeDataTypeCode>4</design:nativeDataTypeCode>
<design:precision>10</design:precision>
<design:scale>0</design:scale>
<design:nullability>Nullable</design:nullability>
<design:uiHints>
<design:displayName>QUANTITYORDERED</design:displayName>
</design:uiHints>
</design:attributes>
<design:usageHints>
<design:label>QUANTITYORDERED</design:label>
<design:formattingHints>
<design:displaySize>11</design:displaySize>
</design:formattingHints>
</design:usageHints>
</design:resultColumnDefinitions>
<design:resultColumnDefinitions>
<design:attributes>
<design:name>PRICEEACH</design:name>
<design:position>4</design:position>
<design:nativeDataTypeCode>8</design:nativeDataTypeCode>
<design:precision>15</design:precision>
<design:scale>0</design:scale>
<design:nullability>Nullable</design:nullability>
<design:uiHints>
<design:displayName>PRICEEACH</design:displayName>
</design:uiHints>
</design:attributes>
<design:usageHints>
<design:label>PRICEEACH</design:label>
<design:formattingHints>
<design:displaySize>22</design:displaySize>
</design:formattingHints>
</design:usageHints>
</design:resultColumnDefinitions>
<design:resultColumnDefinitions>
<design:attributes>
<design:name>ORDERLINENUMBER</design:name>
<design:position>5</design:position>
<design:nativeDataTypeCode>5</design:nativeDataTypeCode>
<design:precision>5</design:precision>
<design:scale>0</design:scale>
<design:nullability>Nullable</design:nullability>
<design:uiHints>
<design:displayName>ORDERLINENUMBER</design:displayName>
</design:uiHints>
</design:attributes>
<design:usageHints>
<design:label>ORDERLINENUMBER</design:label>
<design:formattingHints>
<design:displaySize>6</design:displaySize>
</design:formattingHints>
</design:usageHints>
</design:resultColumnDefinitions>
</design:resultSetColumns>
<design:criteria/>
</design:resultSetDefinitions>
</design:ResultSets>
</model:DesignValues>]]></xml-property>
</oda-data-set>
</data-sets>
<styles>
<style name="report" id="4">
<property name="fontFamily">sans-serif</property>
<property name="fontSize">10pt</property>
</style>
<style name="crosstab-cell" id="5">
<property name="borderBottomColor">#CCCCCC</property>
<property name="borderBottomStyle">solid</property>
<property name="borderBottomWidth">1pt</property>
<property name="borderLeftColor">#CCCCCC</property>
<property name="borderLeftStyle">solid</property>
<property name="borderLeftWidth">1pt</property>
<property name="borderRightColor">#CCCCCC</property>
<property name="borderRightStyle">solid</property>
<property name="borderRightWidth">1pt</property>
<property name="borderTopColor">#CCCCCC</property>
<property name="borderTopStyle">solid</property>
<property name="borderTopWidth">1pt</property>
</style>
<style name="crosstab" id="6">
<property name="borderBottomColor">#CCCCCC</property>
<property name="borderBottomStyle">solid</property>
<property name="borderBottomWidth">1pt</property>
<property name="borderLeftColor">#CCCCCC</property>
<property name="borderLeftStyle">solid</property>
<property name="borderLeftWidth">1pt</property>
<property name="borderRightColor">#CCCCCC</property>
<property name="borderRightStyle">solid</property>
<property name="borderRightWidth">1pt</property>
<property name="borderTopColor">#CCCCCC</property>
<property name="borderTopStyle">solid</property>
<property name="borderTopWidth">1pt</property>
</style>
</styles>
<page-setup>
<simple-master-page name="Simple MasterPage" id="2">
<method name="onPageEnd"><![CDATA[var qtys =
this.getInstancesByElementName("qtyelement");
var tmp=0;
if( qtys != null ){
for( var i=0; i< qtys.length; i++ ){
//Instance of DataItemInstance
var qty = qtys[i];
tmp+=parseInt(qty.getValue());
}

}
reportContext.setPageVariable("pageqty",tmp);]]></method>
<page-header>
<auto-text id="44">
<property name="backgroundColor">#FF8080</property>
<property name="type">page-variable</property>
<property name="pageVariable">pageqty</property>
</auto-text>
</page-header>
<page-footer>
<auto-text id="47">
<property name="backgroundColor">#FF8040</property>
<property name="type">page-variable</property>
<property
name="pageVariable">totalForAllPages</property>
</auto-text>
</page-footer>
</simple-master-page>
</page-setup>
<body>
<table id="9">
<property name="dataSet">Data Set</property>
<list-property name="boundDataColumns">
<structure>
<property name="name">ORDERNUMBER</property>
<text-property
name="displayName">ORDERNUMBER</text-property>
<expression name="expression"
type="javascript">dataSetRow["ORDERNUMBER"]</expression >
<property name="dataType">integer</property>
</structure>
<structure>
<property name="name">PRODUCTCODE</property>
<text-property
name="displayName">PRODUCTCODE</text-property>
<expression name="expression"
type="javascript">dataSetRow["PRODUCTCODE"]</expression >
<property name="dataType">string</property>
</structure>
<structure>
<property name="name">QUANTITYORDERED</property>
<text-property
name="displayName">QUANTITYORDERED</text-property>
<expression name="expression"
type="javascript">dataSetRow["QUANTITYORDERED"]</expression >
<property name="dataType">integer</property>
</structure>
<structure>
<property name="name">PRICEEACH</property>
<text-property
name="displayName">PRICEEACH</text-property>
<expression name="expression"
type="javascript">dataSetRow["PRICEEACH"]</expression>
<property name="dataType">float</property>
</structure>
<structure>
<property name="name">ORDERLINENUMBER</property>
<text-property
name="displayName">ORDERLINENUMBER</text-property>
<expression name="expression"
type="javascript">dataSetRow["ORDERLINENUMBER"]</expression >
<property name="dataType">integer</property>
</structure>
<structure>
<property name="name">Aggregation</property>
<property name="dataType">float</property>
<property name="aggregateFunction">SUM</property>
<list-property name="arguments">
<structure>
<property name="name">Expression</property>
<expression name="value"
type="javascript">row["QUANTITYORDERED"]</expression>
</structure>
</list-property>
</structure>
</list-property>
<property name="pageBreakInterval">4</property>
<column id="38"/>
<column id="39"/>
<column id="40"/>
<column id="41"/>
<column id="42"/>
<header>
<row id="10">
<cell id="11">
<label id="12">
<text-property
name="text">ORDERNUMBER</text-property>
</label>
</cell>
<cell id="13">
<label id="14">
<text-property
name="text">PRODUCTCODE</text-property>
</label>
</cell>
<cell id="15">
<label id="16">
<text-property
name="text">QUANTITYORDERED</text-property>
</label>
</cell>
<cell id="17">
<label id="18">
<text-property
name="text">PRICEEACH</text-property>
</label>
</cell>
<cell id="19">
<label id="20">
<text-property
name="text">ORDERLINENUMBER</text-property>
</label>
</cell>
</row>
</header>
<detail>
<row id="21">
<cell id="22">
<data id="23">
<property
name="resultSetColumn">ORDERNUMBER</property>
</data>
</cell>
<cell id="24">
<data id="25">
<property
name="resultSetColumn">PRODUCTCODE</property>
</data>
</cell>
<cell id="26">
<data name="qtyelement" id="27">
<property
name="resultSetColumn">QUANTITYORDERED</property>
</data>
</cell>
<cell id="28">
<data id="29">
<property
name="resultSetColumn">PRICEEACH</property>
</data>
</cell>
<cell id="30">
<data id="31">
<property
name="resultSetColumn">ORDERLINENUMBER</property>
</data>
</cell>
</row>
</detail>
<footer>
<row id="32">
<property name="backgroundColor">#004080</property>
<cell id="33"/>
<cell id="34"/>
<cell id="35">
<data id="45">
<property name="color">#FFFFFF</property>
<method
name="onCreate"><![CDATA[reportContext.setPageVariable("totalForAllPages ",this.getValue());
]]></method>
<property
name="resultSetColumn">Aggregation</property>
</data>
</cell>
<cell id="36"/>
<cell id="37"/>
</row>
</footer>
</table>
</body>
<property name="pageVariables">
<variable-element name="pageqty">
<property name="type">page</property>
</variable-element>
<variable-element name="totalForAllPages">
<property name="type">report</property>
</variable-element>
</property>
</report>


On 11/11/2010 4:20 AM, R.Murali wrote:
> yes..Sir i got sum for everypage....
> how to get sum of all the pages as grand sum in last page....
Re: How to do Pagination in BIRT [message #639170 is a reply to message #638527] Mon, 15 November 2010 13:36 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
thank u sir...
What is the purpose of .rptdocument
how to create .rptdocument
Am using eclipse 3.6 birt 2.6.1

[Updated on: Mon, 15 November 2010 13:37]

Report message to a moderator

Re: How to do Pagination in BIRT [message #639388 is a reply to message #639170] Tue, 16 November 2010 11:24 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
No Error..But a small pixel size box appears as my output when i click preview ...
What is the Problem and give me solution...
Re: How to do Pagination in BIRT [message #639389 is a reply to message #636454] Tue, 16 November 2010 11:43 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
sir
how to Pass parameter in runtime.
Re: How to do Pagination in BIRT [message #639480 is a reply to message #639388] Tue, 16 November 2010 17:25 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Can you email me a screen shot to jasonweathersby at windstream dot net?

On 11/16/2010 6:24 AM, R.Murali wrote:
> No Error..But a small pixel size box appears as my output when i click
> preview ...
> What is the Problem and give me solution...
Re: How to do Pagination in BIRT [message #639481 is a reply to message #639389] Tue, 16 November 2010 17:26 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

If you are using the viewer, a parameter box should display. If you are
using the RE API just call task.setParameterValue("parmname", value);

Jason

On 11/16/2010 6:44 AM, R.Murali wrote:
> sir
> how to Pass parameter in runtime.
>
Re: How to do Pagination in BIRT [message #639589 is a reply to message #639480] Wed, 17 November 2010 04:30 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
Sorry Sir...
i think some problem with my system....
yesterday i got the error ..
But today it is working fine.....
Thanks for ur response sir....
Re: How to do Pagination in BIRT [message #640442 is a reply to message #639589] Mon, 22 November 2010 07:10 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
am having more than one check box and depending on the which check box selected ,corresponding report for the selected check box should be displayed.
How to do tis sir
Re: How to do Pagination in BIRT [message #640646 is a reply to message #640442] Mon, 22 November 2010 16:42 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

One way to do this is to create a blank report with a list/combo
parameter with a list of report designs eg


detail.rptdesign
detail2.rptdesign
detail3.rptdesign

then add a text element to the canvas with a script similar to this:

<script type="text/javascript">


function forward() {
var temp = new String(location.href);
var detailReport = "<VALUE-OF>params["reportForward"].value</VALUE-OF>";
var TargetURL = temp.replace(/forwarddetail.rptdesign/, detailReport);

location.replace(TargetURL);
return false;
}
forward();
</script>

in the above example the forwarddetail.rptdesign is the name of the
blank report.

Jason

On 11/22/2010 2:11 AM, R.Murali wrote:
> am having more than one check box and depending on the which check box
> selected ,corresponding report for the selected check box should be
> displayed.
> How to do tis sir
Re: How to do Pagination in BIRT [message #640863 is a reply to message #640646] Tue, 23 November 2010 11:23 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
Thanks for your response sir.
Without parameter i want to generate the report in which in should contain 3 check boxes and want to get different reports for different check box selected.How to do this sir..

[Updated on: Tue, 23 November 2010 11:24]

Report message to a moderator

Re: How to do Pagination in BIRT [message #640984 is a reply to message #640863] Tue, 23 November 2010 18:18 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

You want one report that displays 3 check boxes and a submit button? and
when the submit button is pressed display the report with the check box
display? If this is the case you should be able to do this similar to
the previous example I posted using a text element and instead of
running the forward automatically put in a script on the button. Or you
could just add a jsp page to the viewer.

Jason

On 11/23/2010 6:23 AM, R.Murali wrote:
>
> Without parameter i want to generate the report in which in should
> contain 3 check boxes and want to get different reports for different
> check box selected.How to do this sir
Re: How to do Pagination in BIRT [message #641056 is a reply to message #640984] Wed, 24 November 2010 07:20 Go to previous messageGo to next message
R.Murali Missing name is currently offline R.Murali Missing nameFriend
Messages: 30
Registered: November 2010
Member
couldn't able to get your point...can you please provide me with code..
Re: How to do Pagination in BIRT [message #641249 is a reply to message #641056] Wed, 24 November 2010 16:02 Go to previous message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Take a look at this example:

Jason

<?xml version="1.0" encoding="UTF-8"?>
<report xmlns="http://www.eclipse.org/birt/2005/design" version="3.2.22"
id="1">
<property name="createdBy">Eclipse BIRT Designer Version
2.6.1.v20100902 Build &lt;2.6.1.v20100915-1750></property>
<property name="units">in</property>
<property name="iconFile">/templates/blank_report.gif</property>
<property name="bidiLayoutOrientation">ltr</property>
<property name="imageDPI">96</property>
<styles>
<style name="report" id="4">
<property name="fontFamily">sans-serif</property>
<property name="fontSize">10pt</property>
</style>
<style name="crosstab-cell" id="5">
<property name="borderBottomColor">#CCCCCC</property>
<property name="borderBottomStyle">solid</property>
<property name="borderBottomWidth">1pt</property>
<property name="borderLeftColor">#CCCCCC</property>
<property name="borderLeftStyle">solid</property>
<property name="borderLeftWidth">1pt</property>
<property name="borderRightColor">#CCCCCC</property>
<property name="borderRightStyle">solid</property>
<property name="borderRightWidth">1pt</property>
<property name="borderTopColor">#CCCCCC</property>
<property name="borderTopStyle">solid</property>
<property name="borderTopWidth">1pt</property>
</style>
<style name="crosstab" id="6">
<property name="borderBottomColor">#CCCCCC</property>
<property name="borderBottomStyle">solid</property>
<property name="borderBottomWidth">1pt</property>
<property name="borderLeftColor">#CCCCCC</property>
<property name="borderLeftStyle">solid</property>
<property name="borderLeftWidth">1pt</property>
<property name="borderRightColor">#CCCCCC</property>
<property name="borderRightStyle">solid</property>
<property name="borderRightWidth">1pt</property>
<property name="borderTopColor">#CCCCCC</property>
<property name="borderTopStyle">solid</property>
<property name="borderTopWidth">1pt</property>
</style>
</styles>
<page-setup>
<simple-master-page name="Simple MasterPage" id="2">
<page-footer>
<text id="3">
<property name="contentType">html</property>
<text-property
name="content"><![CDATA[<value-of>new Date()</value-of>]]></text-property>
</text>
</page-footer>
</simple-master-page>
</page-setup>
<body>
<text id="7">
<property name="contentType">html</property>
<text-property name="content"><![CDATA[<script
type="text/javascript">


function forwardtst(rpt) {
var temp = new String(location.href);
//alert( temp );
var detailReport = rpt;
var TargetURL = temp.replace(/checkboxdriver.rptdesign/, detailReport);

//alert( TargetURL );
location.replace(TargetURL);

return false;
}

</script>

<table>
Detail.rptdesign: <INPUT TYPE="checkbox" NAME="Item1" VALUE="1"
UNCHECKED onClick="forwardtst('detail.rptdesign')">
<br>
Detail2.rptdesign: <INPUT TYPE="checkbox" NAME="Item2" VALUE="2"
UNCHECKED onClick="forwardtst('detail2.rptdesign')">


</table>
]]></text-property>
</text>
</body>
</report>



On 11/24/2010 2:20 AM, R.Murali wrote:
> couldn't able to get your point...can you please provide me with code..
Previous Topic:Scripted Data Set Parameters dont work in Designer 2.6.1
Next Topic:SVG on OS X
Goto Forum:
  


Current Time: Sat Nov 29 10:16:07 GMT 2014

Powered by FUDForum. Page generated in 0.10975 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software