Discussions
Categories
Choose a Product
THRUST SERVICES
CORE APPS
CE PRODUCTS
...
Quick Links
POPULAR
HELPFUL TIPS
Groups
My Links
FOR SIGNED IN MEMBERS:
Back to website
Home
Designing Analytics Reports
Grouping data on column that is not displayed
Migrateduser
Hi, I am using the Java Design Report API to generate my report design file.<br />
<br />
I would like to be able to group data on a column that is not displayed in the report. How can I do this?<br />
<br />
I have the following code below that groups data on an column that is in the report currently:<br />
<br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
// Table Group
TableGroupHandle group = elementFactory.newTableGroup( );
group.setName("group_colGroup");
group.setKeyExpr( "dataSetRow[\"group_col\"]" ); // just for Servicer
group.setInterval("none");
group.setSortDirection(DesignChoiceConstants.SORT_DIRECTION_ASC);
group.setRepeatHeader(true);
dataTable.getGroups().add(group);
RowHandle grpHdrHandle = elementFactory.newTableRow(dataCols.size());
CellHandle tblCellHandle = (CellHandle) grpHdrHandle.getCells().get(0);
//tblCellHandle.setDrop(DesignChoiceConstants.DROP_TYPE_DETAIL); // just for servicer
DataItemHandle data0 = elementFactory.newDataItem(null);
data0.setResultSetColumn("group_col"); // should be config property !!
tblCellHandle.getContent().add(data0);
group.getHeader().add(grpHdrHandle);
RowHandle groupFooter = elementFactory.newTableRow( dataCols.size() );
String groupFooterPadding=repMetaData.getDataGroupPadding();
groupFooter.getHeight().setStringValue(groupFooterPadding); // should be config property !!
group.getFooter().add(groupFooter);
</pre>
<br />
How can I modify this code if I don't wish to display the group_col column in my report ?<br />
<br />
Thanks for any help in advance
Find more posts tagged with
Comments
There are no comments yet