Create Export From Template

Prerequisites for Creating Export From Template

To simplify the setup of exports there are various predefined export templates available for you to select from.

It should not be necessary to update any of the details for the export however you may do so if required; for example - you may want to modify the default filter condition expression.

Create Export from Template

  1. From the OPERA Cloud menu, select Miscellaneous, select Exports then select General (or other type of export)

  2. Click New from Template.

  3. On the Create New Export prompt; complete the following

    1. Property. Select or confirm the property

    2. Template. Click to select a template from the list. See Export Template Catalogue

    3. Export Name. Enter or confirm a name for the export

    4. Description. Enter a description for the export

  4. Click Create and Continue to the Edit Export page

  5. Export Definition panel will be populated with details from the selected template; these values should not require update

    1. Export Name. Enter or confirm a name for the export

    2. Description. Enter a description for the export

    3. Pre Export Procedure. The pre-export procedure is an internal setup procedure which will be executed prior to the data export. The pre-export procedure is a pre-processor that populates and filters views, and sets variables. If a pre-export procedure is not specified, the export will look at the value(s) selected in the Parameter Form.

    4. Post Export Procedure. The post-export procedure is a post-processor that truncates temp tables following export generation and may also reset parameters that were set for the export.

    5. Filter Condition. Click to edit the expression for the data filter

    6. XML Format. Click to export data in XML format

      1. XML Root Tag. Enter root tag

    7. Filename Formula. Click to edit expression for the export file name

    8. File Extn Formula. Click to edit expression for the export file extension 

    9. Zip file name. Click to edit expression for the export zip file name

  6. Export Run Configuration

    1. End of Day. Click to generate the export during End of Day

    2. Frequency. Select a frequency from the list

    3. Day of Week. Select a day of the week from the list (not enabled for daily frequency)

    4. Parameter Form. Select the parameter form to use when the export is manually generated. (not enabled when End of Day is selected)

  7. Export Content

    1. General Configuration

      1. Always Export Header and Footer. Select to include header and footer lines in the export

      2. Compress Data. Select the separate the data with a delimiter

        1. Column Separator. Select a column (data) delimiter from the list

      3. Add Newline. Select this check box to have each record created on a separate line in the text file

    2. Column Configurations

      1. Select the column options for header, detail and footer using the expression editor; see Using the Expression Editor

  8. Click Save.

Using the Expression Editor

Expression editor provides select-able values to build an SQL expression using String, Number, Date, Boolean, and Conversion functions. You can also select from a list of SQL functions, separators, operators, and system variables such as PMS_P.BUSINESS_DATE or PMS_P.RESORT. Use the [ADD] [ADD BEFORE] and navigation controls to determine the placement of the selected function, operator, separator, string or numeric values.

Example of expressions

Type Expression

Pre Export Procedure

EXP_GENERAL_RESV_PKG.SET_EXP_START_DATE(PMS_P.BUSINESS_DATE)

Post Export Procedure

exp_create_data.delete_report_table

Filter condition

inactive_date is null and NAME_TYPE = 'D' and COUNTRY = 'US' and FIRST is not null and TOTAL_ROOM_REVENUE > '1000'

Filter condition

business_date=to_char(pms_p.business_date-1,'DD-MM-YY')

Filename

'CR'||pms_p.resort||lpad(to_char(pms_p.business_date,'DDD'),3,'0')

Filename

'DRS'||SUBSTR(HOTEL_CODE,1,5)||TO_CHAR(EXP_GENERAL_RESV_PKG.EXP_START_DATE(),'DDD')

Filename

'DCO_'||pms_p.resort||to_char(pms_p.business_date,'MMDDYY')

Filename

'STAT_'||pms_p.resort||'_'||to_char(sysdate,'YYYYMMDD')

Note:

To join multiple string elements together use the ‘||’ concatenation operator in your expression.
  1. Click the pencil icon to create or edit an SQL expression.

  2. Select a procedure, API, operator, function or other element from the list or

  3. Enter text into String field to add text to the expression or

  4. Enter a numeric value to the Number field to add a number to the expression

  5. Click [ADD] to append the selection after the yellow highlighted entry.

  6. Click [REPLACE] to replace the highlighted entry

  7. Click [DELETE] to delete highlighted entry

  8. Use [<] and [>] to move through the entries in the expression.

  9. Repeat steps to construct the expression; inserting elements where required.

  10. Click OK when complete


This image shows the Edit Pre Export Procedure screen details