Like what you see? Have a play with our trial version.

Error rendering macro 'rw-search'

null

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Expand
titleTEXT

This request runs a specified report and returns it in its Text form.

 

Request Elements

The following elements will be passed with this request:

Request Element

Data Type

Description

LoginId

String

Yellowfin web services administrator user Id. This can be the user ID or the email address, depending on the Logon ID method.

This Yellowfin account must have the “web services” role enabled, and must belong to the Default (i.e. Primary) Org.

Password

String

Password of the above account.

OrgId

Integer

Default (i.e. Primary) organization ID within Yellowfin. Always set this to 1.

ReportRequest

String

Web services function. Set this to "TEXT".

ReportIdIntegerAn internal ID to specify the report to be returned as a TEXT representation.


 

Request Example

The following SOAP example shows the parameters that you can pass to this call:

Code Block
languagexml
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://webservices.web.mi.hof.com/">
   <soapenv:Header/>
   <soapenv:Body>
      <web:remoteReportCall>
         <arg0>
            <loginId>admin@yellowfin.com.au</loginId>
            <password>test</password>
            <orgId>1</orgId>
            <reportRequest>TEXT</reportRequest>
            <reportId>60712</reportId>
            </arg0>
      </web:remoteReportCall>
   </soapenv:Body>
</soapenv:Envelope>

 

 

Response Elements

The response will contain these main parameters:

Response Element

Data Type

Description

Retrieval Code

ReportId

Integer

ID of the specified report.

getReportId()

ReportName

String

Name of the specified report.

getReportName()

HitCount

Integer

Number of times the specified report has been accessed.

getHitCount()

FormatCode

String

Format code of the specified report.

getFormatCode()

BinaryData

String

Base64 encoded binary chunk of XLS.

getBinaryData()

ContentType

String

MIME Content Type of this object. Value will be “text/tab-separated-values”.

getContentType()

 

 

Response Example

The service will return the below response, according to our SOAP example:

Code Block
languagexml
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
   <S:Body>
      <ns2:remoteReportCallResponse xmlns:ns2="http://webservices.web.mi.hof.com/">
         <return>
            <author>System Administrator</author>
            <authoringMode>JAVA</authoringMode>
            <averageRunTime>0</averageRunTime>
            <binaryData>Tm90IGZvciBSZS1TYWxlIExpY2VuY2UsLCwKVG9wIE4sQ29tcGFueSBOYW1lLERlbW9ncmFwaGlj
LFN1bSBJbnZvaWNlZCAoUHJlZiBDdXJyZW5jeSkKIlRvcCBOIEFnZW5jaWVzICIsQmFyZ2FpbiBU
cmlwcyxBZHZlbnR1cmUsIiQxMCw4NTYiCiJUb3AgTiBBZ2VuY2llcyAiLEJhcmdhaW4gVHJpcHMs
RmFtaWx5LCIkMjk1LDgyNyIKIlRvcCBOIEFnZW5jaWVzICIsQmFyZ2FpbiBUcmlwcyxMdXh1cnks
IiQxLDAzMiwwNTYiCiJUb3AgTiBBZ2VuY2llcyAiLEJhcmdhaW4gVHJpcHMsUmVsYXhhdGlvbiwi
JDgwLDY2MCIKIlRvcCBOIEFnZW5jaWV . . .</binaryData>
            <canDrill>false</canDrill>
            <category>Tutorial</category>
            <contentType>text/tab-separeted-values</contentType>
            <dashboardEnabled>true</dashboardEnabled>
            <dataOutput>COLUMN</dataOutput>
            <datasource>Ski Team</datasource>
            <errorCode>0</errorCode>
            <formatCode>REPORTANDCHART</formatCode>
            <hitCount>5</hitCount>
            <lastModifiedDate>2017-06-26</lastModifiedDate>
            <lastRunDuration>0</lastRunDuration>
            <lastRunStatus>RUN_NOERROR</lastRunStatus>
            <messages>Successfully Authenticated User: admin@yellowfin.com.au</messages>
            <messages>Loaded Report: 60712 Successfully</messages>
            <messages>Generating TEXT Report</messages>
            <messages>Request Contains No ReportFilter Records.</messages>
            <messages>AGENCYNAME (FilterId: 60723 ) Requires User Prompt</messages>
            <messages>Report Run Successfully</messages>
            <messages>Web Service Request Complete</messages>
            <preRunFilterString><![CDATA[<div class="rptFilterLogicText">
<span class="rptFilterLogicIdentifier">Company Name</span>
In List
<span class="rptFilterLogicIdentifier">[User Prompt]</span>
</div>]]></preRunFilterString>
            <private>false</private>
            <reportDescription>Top N Agencies compared to all other Agencies by demographic</reportDescription>
            <reportId>60712</reportId>
            <reportName>Agency Benchmark</reportName>
            <reportTemplate>REPORTANDCHART</reportTemplate>
            <reportUUID>c83357db-8aef-4ec7-ab72-fce34de9ee77</reportUUID>
            <reportUsage>0</reportUsage>
            <sessionId>0b549fb1c8361edb2b83dee81227e460</sessionId>
            <statusCode>SUCCESS</statusCode>
            <subCategory>Marketing &amp; Booking</subCategory>
            <tags>No tags</tags>
            <viewName>New View</viewName>
         </return>
      </ns2:remoteReportCallResponse>
   </S:Body>
</S:Envelope>

 

Instructions

See below for step-by-step instructions on how to perform this call, using a Java example:

Expand
titleStep-by-step instructions
  • Here's a basic request to perform this call, which includes logging in as the admin user and specifying the web service call to perform:

    Code Block
    languagejava
    ReportServiceRequest rsr = new ReportServiceRequest();
     
    rsr.setLoginId("admin@yellowfin.com.au");
    rsr.setPassword("test");
    rsr.setOrgId(new Integer(1));
    
    rsr.setReportRequest("TEXT");


  • If you need to specify the client org where the report exists, add this to your code:

    Code Block
    languagejava
    rsr.setOrgRef("org1");      // search for the report in this client org



  • Specify a report to view it in its TEXT form:

    Code Block
    languagejava
    rsr.setReportId(60712);



  • Once the request is configured, carry out the call:

    Code Block
    languagejava
    ReportServiceResponse rs=rsc.remoteReportCall(rsr);

    Initialize the Report web service. Click here to learn how to do this. 

 

  • The response returned will contain the parameters related to the report. (See the Response Parameters table above for more details.)


Complete Example

Below is a full example of this function. To use it for yourself, carry out the following the steps:

  1. Copy the code and save it as ws_textreport.jsp.
  2. Put the file in the root folder, which is Yellowfin/appserver/webapps/ROOT.
  3. Adjust host, port, and admin user to add details according to your environment.
  4. Run http://<host>:<port>/ws_textreport.jsp from your Internet browser.

 

Code Block
languagejava
themeEclipse
/*				ws_textreport.jsp   */
 
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ page import="com.hof.util.*, java.util.*, java.text.*" %> 
<%@ page import="com.hof.web.form.*" %>
<%@ page import="com.hof.mi.web.service.*" %>
<%@ page import="javax.xml.bind.JAXBContext" %>
<%@ page import="javax.xml.bind.Marshaller" %>
<%@ page import="java.io.StringWriter" %>
<%@ page import="javax.xml.bind.JAXBElement" %>
<%@ page import="javax.xml.namespace.QName" %>
<%
	ReportService rsc = new ReportService();   		//("localhost", 8080, "admin@yellowfin.com.au", "test", "/services/ReportService");
	ReportServiceRequest rsr = new ReportServiceRequest();
	rsr.setLoginId("admin@yellowfin.com.au");
	rsr.setPassword("test");
	rsr.setOrgId(new Integer(1));
	rsr.setReportRequest("TEXT");
	rsr.setOrgRef("1");
	rsr.setReportId(60712);
	rsr.setReportClientReferenceId("1");
	ReportServiceResponse rs=rsc.remoteReportCall(rsr);
	if ("SUCCESS".equals(rs.getStatusCode())) {
		
		  JAXBContext context = JAXBContext.newInstance(ReportServiceResponse.class);
	        Marshaller m = context.createMarshaller();
	        m.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, Boolean.TRUE); // To format XML
	        JAXBElement<ReportServiceResponse> rootElement = new JAXBElement<ReportServiceResponse>(new QName("ReportServiceResponse"), ReportServiceResponse.class, rs);
	        m.marshal(rootElement,out);    
		//out.write("Success");
	} else {
		out.write("Failure");
		out.write(" Code: " + rs.getErrorCode());
	} 
%>

  


 

Anchor
rtfrtf

RTF is not working prob. both the jsp and soap display a message saying: Unknown Or Unsupported Request: RTF.

...

titleRTF

This request runs a specified report and returns it in its RTF form.

Request Elements

The following elements will be passed with this request:

...

Request Element

...

Data Type

...

Description

...

LoginId

...

String

...

Yellowfin web services administrator user Id. This can be the user ID or the email address, depending on the Logon ID method.

This Yellowfin account must have the “web services” role enabled, and must belong to the Default (i.e. Primary) Org.

...

Password

...

String

...

Password of the above account.

...

OrgId

...

Integer

...

Default (i.e. Primary) organization ID within Yellowfin. Always set this to 1.

...

ReportRequest

...

String

...

Web services function. Set this to "RTF".

...

 

Request Example

The following SOAP example shows the parameters that you can pass to this call:

Code Block
languagexml
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://webservices.web.mi.hof.com/">
   <soapenv:Header/>
   <soapenv:Body>
      <web:remoteReportCall>
         <arg0>
            <loginId>admin@yellowfin.com.au</loginId>
            <password>test</password>
            <orgId>1</orgId>
            <reportRequest>RTF</reportRequest>
            <reportId>60712</reportId>
            </arg0>
      </web:remoteReportCall>
   </soapenv:Body>
</soapenv:Envelope>

 

 

Response Elements

The response will contain these main parameters:

...

Response Element

...

Data Type

...

Description

...

Retrieval Code

...

ReportId

...

Integer

...

ID of the specified report.

...

getReportId()

...

ReportName

...

String

...

Name of the specified report.

...

getReportName()

...

HitCount

...

Integer

...

Number of times the specified report has been accessed.

...

getHitCount()

...

FormatCode

...

String

...

Format code of the specified report.

...

getFormatCode()

...

BinaryData

...

String

...

Base64 encoded binary chunk of RTF.

...

getBinaryData()

...

ContentType

...

String

...

MIME Content Type of this object. Value will be “application/rtf”.

...

getContentType()

 

Instructions

See below for step-by-step instructions on how to perform this call, using a Java example:

...

titleStep-by-step instructions

...

Code Block
languagejava
ReportServiceRequest rsr = new ReportServiceRequest();
 
rsr.setLoginId("admin@yellowfin.com.au");
rsr.setPassword("test");
rsr.setOrgId(new Integer(1));

rsr.setReportRequest("RTF");

...

Code Block
languagejava
rsr.setOrgRef("org1");      // search for the report in this client org

...

Code Block
languagejava
rsr.setReportId(60712);

...

Code Block
languagejava
ReportServiceResponse rs=rsc.remoteReportCall(rsr);

Initialize the Report web service. Click here to learn how to do this. 

 

...

Complete Example

Below is a full example of this function. To use it for yourself, carry out the following the steps:

  1. Copy the code and save it as ws_rtfreport.jsp.
  2. Put the file in the root folder, which is Yellowfin/appserver/webapps/ROOT.
  3. Adjust host, port, and admin user to add details according to your environment.
  4. Run http://<host>:<port>/ws_rtfreport.jsp from your Internet browser.

 

Code Block
languagejava
themeEclipse
/*				ws_rtfreport.jsp   */
 
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ page import="com.hof.util.*, java.util.*, java.text.*" %> 
<%@ page import="com.hof.web.form.*" %>
<%@ page import="com.hof.mi.web.service.*" %>
<%@ page import="javax.xml.bind.JAXBContext" %>
<%@ page import="javax.xml.bind.Marshaller" %>
<%@ page import="java.io.StringWriter" %>
<%@ page import="javax.xml.bind.JAXBElement" %>
<%@ page import="javax.xml.namespace.QName" %>
<%
	ReportService rsc = new ReportService();   		//("localhost", 8080, "admin@yellowfin.com.au", "test", "/services/ReportService");
	ReportServiceRequest rsr = new ReportServiceRequest();
	rsr.setLoginId("admin@yellowfin.com.au");
	rsr.setPassword("test");
	rsr.setOrgId(new Integer(1));
	rsr.setReportRequest("RTF");
	rsr.setOrgRef("1");
	rsr.setReportId(60712);
	rsr.setReportClientReferenceId("1");
	ReportServiceResponse rs=rsc.remoteReportCall(rsr);
	if ("SUCCESS".equals(rs.getStatusCode())) {
		
		  JAXBContext context = JAXBContext.newInstance(ReportServiceResponse.class);
	        Marshaller m = context.createMarshaller();
	        m.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, Boolean.TRUE); // To format XML
	        JAXBElement<ReportServiceResponse> rootElement = new JAXBElement<ReportServiceResponse>(new QName("ReportServiceResponse"), ReportServiceResponse.class, rs);
	        m.marshal(rootElement,out);    
		//out.write("Success");
	} else {
		out.write("Failure");
		out.write(" Code: " + rs.getErrorCode());
	} 
%>

  

 

Anchor
print
print

Expand
titlePRINT

The web service returns a report in a printable format rather than the default.

 

Request Elements

The following elements will be passed with this request:

Request Element

Data Type

Description

LoginId

String

Yellowfin web services administrator user Id. This can be the user ID or the email address, depending on the Logon ID method.

This Yellowfin account must have the “web services” role enabled, and must belong to the Default (i.e. Primary) Org.

Password

String

Password of the above account.

OrgId

Integer

Default (i.e. Primary) organization ID within Yellowfin. Always set this to 1.

ReportRequest

String

Web services function. Set this to "PRINT".

ReportIdIntegerAn internal ID to specify the report to be returned in a printable format.


 

Request Example

The following SOAP example shows the parameters that you can pass to this call:

Code Block
languagexml
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://webservices.web.mi.hof.com/">
   <soapenv:Header/>
   <soapenv:Body>
      <web:remoteReportCall>
         <arg0>
            <loginId>admin@yellowfin.com.au</loginId>
            <password>test</password>
            <orgId>1</orgId>
            <reportRequest>PRINT</reportRequest>
            <reportId>56401</reportId>
            </arg0>
      </web:remoteReportCall>
   </soapenv:Body>
</soapenv:Envelope>

 

 

Response Elements

The response will contain these main parameters:

Response Element

Data Type

Description

Retrieval Code

Chart

ReportChart[]

Array of ReportChart objects that contains multiple chart bitmaps when attached to a HTML report response.

getCharts()

ReportBinaryObject

ReportBinaryObject[]

Array of ReportBinaryObject objects that contain BLOBs and CLOBs.

getBinaryObjects()

ReportStyles

String

CSS styles.

getReportStyles()

Breadcrumbs

Breadcrumb[]

Array of Breadcrumb objects.

getBreadcrumbs()

SeriesSelection

SeriesSelection[]

Array of SeriesSelection objects.

getSeriesSelections()

TimeAggregationSelection

TimeAggregationSelection[]

Array of TimeAggregationSelection objects.

getTimeAggregationSelection()

ReportTabSelection

ReportTabSelection[]

Array of ReportTabSelection objects.

getReportTabSelection()

ReportPageSelection

ReportPageSelection[]

Array of ReportPageSelection objects.

getReportPageSelection()

TimeSliderSelection

TimeSliderSelection[]

Array of TimeSliderSelection objects.

getTimeSliderSelection()

SortableColumns

SortableTableColumn[]

Array of SortableTableColumn objects.

getSortableColumns()

SelectedSortColumn

Integer

Column used for sorting. The index here applies to the column index within the report.

getSelectedSortColumn()

SelectedSortOrder

Integer

The sort order of the column used for sorting (0 for ascending and 1 for descending).

getSelectedSortOrder()

DrillCode

String

Drill type if available on the report.

getDrillCode()

RelatedReports

RelatedReport[]

Array of RelatedReport objects. These are reports that are tabbed/codisplayed to the main report.

getRelatedReports()

BinaryData

String

Base64 encoded binary chunk of the HTML document.

getBinaryData()

Private

 

Determines if the report is a private or a public one.

getPrivate()

ContentType

String

MIME ContentType of the returned object. Value will be “text/html”.

getContentType()

CanDrill

Boolean

If the report is able to drill or not.

getCanDrill()

GoogleMaps

GMap

Array of GMap objects.

getGoogleMaps()

 

 

Response Example

The service will return the below response, according to our SOAP example:

Code Block
languagexml
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
   <S:Body>
      <ns2:remoteReportCallResponse xmlns:ns2="http://webservices.web.mi.hof.com/">
         <return>
            <author>System Administrator</author>
            <authoringMode>JAVA</authoringMode>
            <averageRunTime>0</averageRunTime>
            <binaryData>PHN0eWxlIHR5cGU9InRleHQvY3NzIj4KLm11bHRpV2lkZ2V0Q2FudmFzRWRpdG9yIHsKCXBvc2l0
aW9uOiByZWxhdGl2ZTsKfQoKLm11bHRp . . .</binaryData>
            <canDrill>false</canDrill>
            <category>Audit Reports</category>
            <contentType>text/html</contentType>
            <dashboardEnabled>true</dashboardEnabled>
            <dataOutput>COLUMN</dataOutput>
            <datasource>Yellowfin Configuration Database</datasource>
            <drillCode>NODRILL</drillCode>
            <errorCode>0</errorCode>
            <formatCode>REPORTANDCHART</formatCode>
            <hitCount>30</hitCount>
            <lastModifiedDate>2018-07-02</lastModifiedDate>
            <lastRunDuration>0</lastRunDuration>
            <lastRunStatus>RUN_NOERROR</lastRunStatus>
            <messages>Successfully Authenticated User: admin@yellowfin.com.au</messages>
            <messages>Loaded Report: 56401 Successfully</messages>
            <messages>Generating HTML Report</messages>
            <messages>Request Contains No ReportFilter Records.</messages>
            <messages>Report Run Successfully</messages>
            <messages>Web Service Request Complete</messages>
            <preRunFilterString><![CDATA[<div class="rptFilterLogicText">
<span class="rptFilterLogicIdentifier">Active Session Start</span>
Is Not Null
<span class="rptFilterLogicIdentifier"></span>
</div>]]></preRunFilterString>
            <private>false</private>
            <relatedReports/>
            <reportDescription/>
            <reportId>56401</reportId>
            <reportName>Active Sessions</reportName>
            <reportStyle>td.rpthdrcol {
   position: relative;
}
img.rptcolmenu {
   position: absolute;
   right: 5px;
   top: 0;
   bottom: 0;
   margin: auto 0;
   cursor: pointer;
}
td.rpthdrcol div.rptdata {
   padding-right: 20px;
}
td.reportChartCell {
   vertical-align: top;
}
div.reportChart {
   position: relative;
   display: inline-block;
}
img.reportChart {
   position: absolute;
   left: 0;
   top: 0;
}
.
.
.
table.rpt56401sectionsummary {
   margin-bottom: 20px;
}
.printpagebreak {
   PAGE-BREAK-BEFORE: always;
}</reportStyle>
            <reportTemplate>REPORTANDCHART</reportTemplate>
            <reportUUID>594d4da4-1b58-44d3-bf4f-11456a42f68c</reportUUID>
            <reportUsage>100</reportUsage>
            <selectedSortColumn>-1</selectedSortColumn>
            <selectedSortOrder>0</selectedSortOrder>
            <sessionId>7fc9ad31786cfd1ca10605c301551534</sessionId>
            <sortableColumns/>
            <sortableColumns/>
            <sortableColumns/>
            <statusCode>SUCCESS</statusCode>
            <subCategory>Admin Reports</subCategory>
            <tags>No tags</tags>
            <viewName>NEW VIEW</viewName>
         </return>
      </ns2:remoteReportCallResponse>
   </S:Body>
</S:Envelope>

 

Instructions

See below for step-by-step instructions on how to perform this call, using a Java example:

Expand
titleStep-by-step instructions
  • Here's a basic request to perform this call, which includes logging in as the admin user and specifying the web service call to perform:

    Code Block
    languagejava
    ReportServiceRequest rsr = new ReportServiceRequest();
     
    rsr.setLoginId("admin@yellowfin.com.au");
    rsr.setPassword("test");
    rsr.setOrgId(new Integer(1));
    
    rsr.setReportRequest("PRINT");


  • If you need to specify the client org where the report exists, add this to your code:

    Code Block
    languagejava
    rsr.setOrgRef("org1");      // search for the report in this client org



  • Specify which report to convert into a printable format:

    Code Block
    languagejava
    rsr.setReportId(60712);



  • Once the request is configured, carry out the call:

    Code Block
    languagejava
    ReportServiceResponse rs=rsc.remoteReportCall(rsr);

    Initialize the Report web service. Click here to learn how to do this. 

 

  • The response returned will contain the parameters related to the report. (See the Response Parameters table above for more details.)


Complete Example

Below is a full example of this function. To use it for yourself, carry out the following the steps:

  1. Copy the code and save it as ws_printreport.jsp.
  2. Put the file in the root folder, which is Yellowfin/appserver/webapps/ROOT.
  3. Adjust host, port, and admin user to add details according to your environment.
  4. Run http://<host>:<port>/ws_printreport.jsp from your Internet browser.

 

Code Block
languagejava
themeEclipse
/*				ws_printreport.jsp   */
 
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ page import="com.hof.util.*, java.util.*, java.text.*" %> 
<%@ page import="com.hof.web.form.*" %>
<%@ page import="com.hof.mi.web.service.*" %>
<%@ page import="javax.xml.bind.JAXBContext" %>
<%@ page import="javax.xml.bind.Marshaller" %>
<%@ page import="java.io.StringWriter" %>
<%@ page import="javax.xml.bind.JAXBElement" %>
<%@ page import="javax.xml.namespace.QName" %>
<%
	ReportService rsc = new ReportService();   //("localhost", 8080, "admin@yellowfin.com.au", "test", "/services/ReportService");
	ReportServiceRequest rsr = new ReportServiceRequest();
	rsr.setLoginId("admin@yellowfin.com.au");
	rsr.setPassword("test");
	rsr.setOrgId(new Integer(1));
	rsr.setReportRequest("PRINT");
	rsr.setReportId(60712);
	ReportServiceResponse rs=rsc.remoteReportCall(rsr);
	
	if ("SUCCESS".equals(rs.getStatusCode())) {
		
		%> <xmp> <% 
		  JAXBContext context = JAXBContext.newInstance(ReportServiceResponse.class);
	        Marshaller m = context.createMarshaller();
	        m.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, Boolean.TRUE); // To format XML
	        JAXBElement<ReportServiceResponse> rootElement = new JAXBElement<ReportServiceResponse>(new QName("ReportServiceResponse"), ReportServiceResponse.class, rs);
	        m.marshal(rootElement,out);    
	        %></xmp><%
		//out.write("Success");
	} else {
		out.write("Failure");
		out.write(" Code: " + rs.getErrorCode());
	} 
%>

  


 

...