Argomento precedente: GetReportsByFolderNameAdvanced

Argomento successivo: GetReportDataAndExport

GetReportData

Description

This method returns report data as XML and optionally generates a GIF image with the report chart.

Syntax

A typical syntax for this method is shown. Note that the exact syntax to use depends on the type of protocol used to communicate with the web service.

XmlNode

GetReportData (
string

sessionID,
int

FavoriteID,
int

pictureRequest,
int

width,
int

height)

Parameter

Name

Type

Description

sessionID

string

Current session ID to perform authentication check.

favoriteID

int

ID of the report that needs to be retrieved.

pictureRequest

int

Generate report picture and return path. 1 = yes; 0 = no.

width

int

Width of picture.

height

int

Height of picture.

Return Value

Report outputs differ according to report type. The Reports Web service adds a path specifies path to the generated report image:

For normal, compound and free-form reports (with chart):

<RESULT ... HAS_CHART ="1/0">
    <ITEM ...>
        .
	.
	.
       <PICTURE_PATH>"<REPORTID><NUM><COUNT>".JPG </ PICTURE_PATH >
     </ITEM>
</RESULT>

For Group reports:

<RESULT ... HAS_CHART =”1/0”>
    <ITEM ...>
        .
	.
	.
       <PICTURE_PATH>"<REPORTID><NUM><COUNT>".JPG </ PICTURE_PATH >
     </ITEM>
     <ITEM ...>
        .
	.
	.
       <PICTURE_PATH>"<REPORTID><NUM><COUNT>".JPG</ PICTURE_PATH >
     </ITEM>

</RESULT>

Remarks

All parameters are mandatory.

If an image is not requested, only the report attributes are returned.

The parameters “PictureRequest”, “width”, and “height” are relevant only to reports that have pictures.

Free-form reports that contain parameters are not supported by this service.

In Report Outputs, HAS_CHART="1" indicates that for this report a report image can be generated with the new tag PICTURE_PATH. The location of the tag depends on the report type. The template "<REPORTID><NUM><COUNT>".JPG will be used to store the image name, where:

Sample Scenarios

Possible scenarios to generate request report data:

Request

Result

Normal report

Report data is returned.

Normal report with chart

Report data is returned, report chart is generated and included in XML data.

Freeform report with chart

Report data is returned, report chart is generated and included in XML data.

Freeform report with parameters

While report parameters have valid default values that report data is returned, otherwise error is returned.

Freeform report without chart

Report data is returned.

Compound report

Report data is returned.

Group report

Report data is returned.

Compound report with chart

Report data is returned, report chart is generated and included in XML data.

Group report with chart

Report data is returned, report chart is generated and included in XML data.

Report does not exist

Error is returned "OE_REPORT_NOT_EXIST".

Illegal report id is supported

Error is returned "OE_ILLEGAL_PARAMETER".

Report is not permitted

Error is returned "OE_NO_USER_PERMISSION".