Installing and Configuring Advanced Reports for Trend Calculation

Scenario: You want to integrate Advanced Reports for Trend Calculation with the management platform, configure the reports, and schedule them to run automatically.

 

Reference: For background information, see the reference section.

 

Workflow diagram:

 

Prerequisites:

  • The extension Advanced Reporting is installed and added to the project.
  • Advanced Reporting is configured, and the templates are synchronized.
  • For viewing a report in Excel, Microsoft Excel 2007 or later is installed on your system.
  • During automatic scheduling of reports to route the report to email, email settings are configured.

 

Steps:

1 – Configure Trend Calculation Reports
  1. Select Applications > Advanced Reporting.
  1. In the Application Viewer tab, click the Configuration Page.
  • The Advanced Reporting Configuration Page displays.
  1. Click Advanced.
  1. In the Trend Calculation Report Setting row, click Edit.
  • The Parameter dialog box displays.
  1. Set the fields to your preferences, and then click Execute.
  • This completes the configuration of Advanced Reports for Trend Calculation.

 

2 – Create a Trend Calculation Object
  • Trend Logs are available.
  • System Manager is in Engineering mode.
  • The default View is set to Show Description.
  1. Select Applications > Advanced Reporting > Trend Calculations.
  1. Select the Trend Calculation tab.
  1. In the Main expander, enter a new name in the Description field.
  1. In the List of Trends and Formulas expander, do the following:
    a.
    Select Applications > Trends > Offline Log Objects > [network name] > Hardware > [automation station] > [offline trend log object].
    NOTE: You can also select either an offline trend log multiple object from Offline Log Objects folder or an online trend log object from Online Log Objects folder.
    b. Drag-and-drop the selected trend log object to the text box that displays below Trend Object.
    c. Click the drop-down list that displays below Trended Object, and select the appropriate trended object.
    NOTE
    : You can select the appropriate trended object only in case of offline trend log multiple object.
    d. (Optional) In order to select Table, Charts, and Right Axis for each individual Trend Object, select the corresponding checkbox that displays below Table, Charts and Right Axis.
    e. (Optional) Specify the formula in the Formula field.
    NOTE 1: The mathematical operators, comparison and logical operators (for example, +, -, /, *, %, >, <, ==, !=, &&, ||) and brackets ( ) are supported in Formula field, in order to create the formula. For example, (((TD1+TD2+TD3)/TD4)%TD5), (((TD1*TD2)/TD3)-(TD4+TD5)), ((TD1>9)||(TD2<10)), ((TD1>9)&&(TD2<10)), ((TD1+TD2)!=(TD3+TD4)) etc. The mathematical functions can also be performed on either one or multiple trend definition (for example, COS(TD1), (SQRT(TD1)*COS(TD2), (SQRT(TD1)+SQRT(TD2))/SQRT(TD3), POW(TD1)(2), etc.).
    NOTE 2: If the mathematical function are specified in small letters e.g. cos, sin, tan etc. then the trend calculations are incorrect. For list of mathematical functions that are supported in the Formula field, see Trend Calculation Workspace.
  1. In the Properties expander, do the following:
    a. For Time Aggregation, enter a value in the Time field and thereafter select one of the time units: Minutes, Hours or Days from the drop-down list. From the Type drop-down list, select one of the aggregation type: Average, Minimum or Maximum.
    b. (Optional) For Display in Report, select the corresponding checkbox that displays next to Legend (List of trend and formula), Display charts, Display table, and Display summary table.
    c. (Optional) For Additional Display for Report and Export, select the corresponding checkbox that displays next to Average, Summation, Minimum, and Maximum.
  1. Click Save As .
  • The Save Object As dialog box displays.
  1. Enter a name and description.
  1. Click OK.
  • The new trend calculation object appears below the Trend Calculations node in the System Browser.
    NOTE: To create, modify, view and delete trend calculation folders and objects, you must have application rights (Show and Configure) on Advanced Reporting Trend Calculation, and also have Create and Delete scope rights. You will require minimum one Trend Object and time interval specified, to create a trend calculation object.

 

3 – Run a Report
  • System Manager is in Operating mode.
  1. Select Applications > Advanced Reporting > Trend Calculations.
  1. Select the trend calculation object for which you want to generate a report.
  • The two reports (for example, Trend Calculation and Trend Calculation For XLS) associated with the selected trend calculation object displays in the Application Viewer tab.
  1. Do one of the following:
  • To run a Trend Calculation report:
    a. Click Trend Calculation, in the Application Viewer tab.
    b. In the Parameter dialog box, select either the appropriate option from the drop-down list for Time Range for Report Content or specify the value for From Date, To Date. Specify the title for Alternative title to the default, and purpose for Alternative Purpose to the default in the text box.
    c. Click Execute.
  • To run a Trend Calculation For XLS report:
    a. Click Trend Calculation For XLS, in the Application Viewer tab.
    b. In the Parameter dialog box, select either the appropriate option from the drop-down list for Time Range for Report Content or specify the value for From Date, To Date in the text box.
    c. Click Execute.
  • The Trend Calculation report or the Trend Calculation For XLS report displays in the Application Viewer tab, according to the selection.
    NOTE: If you want any specific parameter to have NULL value in the Parameter dialog box, then select the Null Value radio button.

 

4 – Create a Link for Executing Reports
  • System Manager is in Operating mode.
  1. Select the trend calculation object for which you want to generate a report.
  • The two reports (for example, Trend Calculation and Trend Calculation For XLS) associated with the selected trend calculation object displays in the Application Viewer tab.
  1. Select the report that you want to schedule.
  1. Click Save As .
  1. In the Save As dialog box, select the destination to save the link.
  1. Enter a name and description, and click OK.
  • The saved link displays in the Applications > Links folder.

 

5 – Set User Credentials
  • System Manager is in Operating mode.
  1. In System Browser, select Application View.
  1. Navigate to Applications > Links.
  1. Select the link(s) whose credentials you want to set.
    NOTE: If you select multiple links, the selected software account is applied to all of them.
  1. Click Set Credentials .
  • The Set Credentials dialog box displays.
  1. From the User Account drop-down menu, select the appropriate user from the list of existing software accounts.
    NOTE: You must choose a user with the appropriate privileges. The language associated with the software account determines the language for any reports generated with this account.
  1. In the Extended Operation tab, specify the parameter values for the link.
  • The user credentials are set for the link and parameter values specified.
    NOTE: In the Operating mode, you can run a report in the Application Viewer by selecting the link from Applications > Links, if the value of the P2 parameter is set to HTML. However, if the value of the P2 parameter is set to any other value (for example, XLSX, DOCX, PDF), then you cannot run the report in the Application Viewer. In this case, you can run the report by clicking Execute in the Extended Operation pane, and specifying the required parameter values.

 

6 – Schedule Automatic Execution of a Trend Calculation Report
  • System Manager is in Engineering mode.
  1. In System Browser, select Application View.
  1. Select Applications > Logics > Reactions.
  1. In the Reaction Editor tab, open the Output expander, and then open the Action expander.
  1. From the Links folder, drag the link to the Scope/Target area.
  1. Select the newly added instruction row, and do the following:
  • To send the report as an email, in the Command drop-down list, select Email [SendEmailExecute].
  • To send the report to a folder, in the Command drop-down list, select Execute [WebAppExecute].
  • In the File Extension drop-down list, select the format of the file. The value specified in this field must be the same as the P2 parameter value specified in the Extended Operations tab. For example, if you have specified PDF as the P2 parameter value, then you must select PDF as the file extension in this field.
  • In the File Name field, enter the file name of the report output file.
  • In the File Path field, enter the location to save the report output file. For example, C:\Projects\NewReports.
    NOTE: If you specify the location, the report is saved to this location and will also be sent as an email attachment.
  • In the Section drop-down list, select Save Document [1].
  • In the TimeStamp field, specify the timestamp format that is to be appended to the file name—for example, dd-MM-yyyy.hhmmss.
  1. Open the Triggers expander, and then open the Time and Organization Mode expander.
  1. Enter the date and time you want the report to run.
  1. Click Save As .
  • The Save Object As dialog box displays.
  1. Enter a name and description, and then click OK.
  • Depending on the value specified in the Command drop-down list, the report runs at the date and time specified in the reaction and is either sent as an attachment to the configured email recipients or to the report output folder specified in the File Path field.