Package Formula Functions

City Tax

See About City Tax Function.

Direct Bill Fee

Description

This function adds a flat fee when posting a package under the following conditions:
  • The payment method for the reservation Billing Window is Direct Bill (based on the Direct Bill Settlement OPERA Control)

Function

direct_bill_fee(resv_name_id,fee_amount, UDF Name, Location,Billing Windows)

Parameter

Parameter Description

in_resv_name_id

System-assigned reservation ID. Provided by the function. The default is null.

fee_amount

Fee to be posted when the direct bill payment method is selected as payment method.

UDF Name

UDF field for Y/N entry. If the value is not set, UDFC 18 defaults.

Location

RESV or PROFILE - The defined UDF is used from either reservation or profile.

Billing Windows

Select the Billing windows (1 to 8, multi-select) that must be considered before posting the Direct Bill Fee.

Example

direct_bill_fee(resv_name_id,20,UDFC10,'RESV',1)

Posts a 20 amount to Window #1 if UDFC10 is set to "Y" in Reservation.

Note:

  • If no resv_name_id exists, the function returns 0. Therefore, a rate query without a reservation does not include the Direct Bill Fee amount.

  • When creating a reservation the function returns a 0 until the reservation is saved and a resv_name_id becomes available.

  • If a package is set up as Add To Rate Combined Line and attached to a rate code or directly to a reservation, the package amount would be 0 and the reservation would therefore not include the Direct Bill Fee.

  • Refresh rates after saving reservation changes to display the correct rate.

Float Person Charge Flat

This function provides for package allowance with a Flat Amount calculation rule and a Floating Allowance per Stay posting rhythm if the number of persons is greater than 0. If the number of persons is 0, no package allowance is posted.

Function

float_flat_allowance_person (RESV_NAME_ID, in_price, in_allowance)

Parameter

Parameter Description

RESV_NAME_ID

System-assigned reservation ID. Provided by the function.

in_price

The package price.

in_allowance

The allowance amount. If the allowance value is not entered, or if the allowance value entered is less than the price, the allowance is set equal to the price.

Example

If the package formula entered is:
float_flat_allowance_person (RESV_NAME_ID, 10, 20)
and the reservation has 1 adult, the package has a 20 allowance. If the reservation has 0 adults and 0 children, no allowance is posted.

Note:

When this UDF is entered in the Formula field, the Allowance check box is automatically selected and the Posting Rhythm is automatically set to Floating Allowance Per Stay. For proper functionality of this feature, the Calculation Rule is automatically set to Per Person even though the amount posted will be a flat amount.

PERC City Tax

This function calculates a generate amount on a room charge that has an inclusive tax component, when the inclusive component is not to be considered in the generate calculation. This function might be used, for example, where a room service tax must be calculated for a room charge that has an inclusive tax.

Function

perc_city_tax('RESV_NAME_ID',tax,inclusive_tax)

Parameter

Parameter Description

RESV_NAME_ID

System-assigned reservation ID. Provided by the function.

tax

Tax to be applied to room charge after removing inclusive tax.

inclusive_tax

Inclusive tax included in room charge.

Example

Assume you have Room Charge transaction code 0010 that has an inclusive generate of 10% (transaction code 0195). You want to calculate a 5% Room Service Tax (transaction code 0199) as an exclusive generate on 0010.
  1. Create package RMSERVICE with transaction code 0195. Specify UDF formula: perc_city_tax('RESV_NAME_ID',5,10) and Add Rate Separate Line selected.

  2. Create rate code ABCD with transaction code 0010 (Inclusive Tax check box selected).

  3. Add package RMSERVICE to rate code ABCD. The wrapper transaction code (to which room and tax is posted) is 8002. The Rate Detail amount = $100. The following postings appear on the folio:
    • Room Charge - Transaction code 8002 $100

    • Room Service Tax - Transaction code 0199 $4.55

Database details would reveal the following values underlying these postings:

Trn. Code Amount

0010

90.91

0195

9.09

0199

4.55

Note:

When a rate code includes a package that uses the Perc City Tax formula, the Rate Info screen accessed via the Rate Query (F5) screen or from the Reservation screen will reflect the Perc City Tax calculation.

The perc_city_tax_hamburg(resv_name_id)UDF is used in the package configuration to calculate the city tax based on the defined purpose of the stay on the reservation. To indicate which Purpose of Stay values qualify for city tax, the description of the purpose should include ‘*’ in the beginning of the description.

An inclusive generate must be attached to the transaction code used to configure the City Tax Package.

The UDF room rate ranges per person and the qualified city tax amounts are defined as follows and cannot be modified:
  • From 0.00 to 30.00 = 1.00.

  • From 30.01 to 60.00 = 3.00.

  • From 60.01 to 90.00 = 5.00.

  • From 90.01+, each additional 30.00 increases by increments of 2.00.

RT Extra Adult Charge

Description

This function calculates the package inclusive rate for a number of adults greater than a base number, per stated room types. Any price information provided in the Package Details is overridden by this function.

Function

rt_extra_adult (in_resv_name_id, X, Y, 'rmtype_1,rmtype_2,...rmtype_n')

Parameter

Parameter Description

in_resv_name_id

System-assigned reservation ID. Provided by the function. The default is null.

X

Base number of adults.

Y

Amount to be added for each adult over the base number specified by X.

rmtype_1...rmtype_n

Room types to which this calculation applies. Comma separated list.

Example

Rate code LEISURE, which includes a package, is priced at $150. If the package formula entered is:

rt_extra_adult (in_resv_name_id, 7, 15, 'DLX,STD')

any adult over seven adults will add $15 to the rate query amount for the LEISURE rate on room types DLX and STD. For eight adults, the rate would be priced at $165 rather than $150.

RT Extra Adult Plus Bucket 1

Description

This function calculates the package inclusive rate for a total number of adults plus children in child bucket 1 that is greater than a base number, per stated room types. Any price information provided in the Package Details is overridden by this function. This function will automatically refresh the total rate value shown in the Reservation screen Total field when the number of adults and/or children in child bucket 1 is changed.

Function

rt_extra_adult_n_bucket1 (in_resv_name_id, X, Y, 'rmtype_1,rmtype_2,...rmtype_n')

Parameter

Parameter Description

in_resv_name_id

System-assigned reservation ID. Provided by the function. The default is null.

X

Base number of adults plus number of children in child bucket 1.

Y

Amount to be added for each adult over the base number specified by X.

rmtype_1...rmtype_n

Room types to which this calculation applies. Comma separated list.

Example

Rate code LEISURE, which includes a package, is priced at $150. If the package formula entered is:

rt_extra_adult_n_bucket1(in_resv_name_id, 7, 15, 'DLX,STD')

Any person over seven adults plus children in child bucket 1 will add $15 to the rate query amount for the LEISURE rate on room types DLX and STD. For five adults and three children in child bucket 1, the rate would be priced at $165 rather than $150.

RT Extra Adult Plus Bucket 2

Description

This function calculates the package inclusive rate for a total number of adults plus children in child bucket 2 that is greater than a base number, per stated room types. Any price information provided in the Package Details is overridden by this function. This function will automatically refresh the total rate value shown in the Reservation screen Total field when the number of adults and/or children in child bucket 2 is changed.

Function

rt_extra_adult_n_bucket2 (in_resv_name_id, X, Y, 'rmtype_1,rmtype_2,...rmtype_n')

Parameter

Parameter Description

in_resv_name_id

System-assigned reservation ID. Provided by the function. The default is null.

X

Base number of adults plus number of children in child bucket 2.

Y

Amount to be added for each adult over the base number specified by X.

rmtype_1...rmtype_n

Room types to which this calculation applies. Comma separated list.

Example

Rate code LEISURE, which includes a package, is priced at $150. If the package formula entered is:

rt_extra_adult_n_bucket2 (in_resv_name_id, 7, 15, 'DLX,STD')

Any person over seven adults plus children in child bucket 2 will add $15 to the rate query amount for the LEISURE rate on room types DLX and STD. For five adults and three children in child bucket 2, the rate would be priced at $165 rather than $150.