10 June 2009 - 3.0-beta-2 user guide eclipse intellij netbeans maven download nightly forum bugs blog sf.net eviware


Eviware Logo

SubReports

Subreport Tab contains toolbar with subreports operations , subreport list and subreport editor .

Subreports Operations

Subreport Operations are: add subreport , save subreport , clone subreport , remove and rename subreport. Operations save, clone, remove and rename require that subreport be selected and that its scope is PROJECT .

Subreport List

This section of subreport panel shows:

  • subreport name - subreport name
  • subreport type - type of subreport , shows for what item it could be used when generating reports
  • subreport scope - show subreport scope
  • subreport data source - show data source exposed by this subreport.

Subreport Editor

Content missing...

Add Subreport

Adding subreport is easly done trough wizard. See picture:

For each subreport here is defined:

  • name - uniq name for subreport
  • subreport type - for which item this subreport is valid
  • subreport data source - data source for this subreport
  • subreport template - jasper report template for this subreport

Save Subreport

Save Report operation save subreport to file system if it is GLOBAL scope or to project if it is PROJECT scope.

Clone Subreport

This operation clone selected subreport. Cloned subreport is added to current project.

Remove Subreport

This operation removes subreport if it is PROJECT scope.

Rename Subreport

This operation renames subreport if it is PROJECT scope. New subreport name can not be same as existing report or subreport.

SubReport in soapUI Pro

Generally there are no much difference in beatween subreport in soapUI and ordinary jasper report subreport. Each subreport is exposing data fields from one data set. Also, its data presentation could be influenced by parameters passed from main report or/and other parameters.

Accessing subreports in main report

Accessing subreport in main report in soapUI Pro is very easy using build in url handler subreport. See example:

<subreport isUsingCache="true">
    <reportElement positionType="Float" isPrintRepeatedValues="false" x="0" y="0" width="500" height="30"/>
    <dataSourceExpression>$P{ReportMetrics}</dataSourceExpression>
    <subreportExpression>"subreport:MetricsReport"</subreportExpression>
</subreport>
         	

In

         	
    <dataSourceExpression>$P{ReportMetrics}</dataSourceExpression>
    
    
is parameter representing data source for given subreport. Inserting this parameter is handled by soapUI Pro, so user when adding subreport to main report does not have to take care of it. This parameter is added to subreport when it is added to soapUI Pro.

While this:

         	
    <subreportExpression>"subreport:MetricsReport"</subreportExpression>
         	
         	
is URL handler to subreport. It is pointing to subreport that is already added to soapUI Pro. It handles finding subreport, compaling it and inserting in main report.

This concept is not mandatory, regular jasper report concept with absoluth path names to subreport and/or inserting datasources is supported by soapUI Pro.

There are other posibilities for changing how main report look and feel, for showing subreports based on does data exists or not, report flow for different formats etc...All that is explaind in Cusomizing Report.


Next: Templates