PricerFromDB

PricerFromDB can be used to price any product. It does not compute any pricer measure, it retrieves pre-computed pricer measures stored in the database at a given date. These pricer measures can be computed by Calypso processes or imported from external systems.

PricerFromDB has two modes of operation:

If pricing parameter USE_MARKS = True, PricerFromDB retrieves pricer measures from PL Marks. PL Marks are searched by Trade or Position ID, Pricing Env, Valuation Date, Measure Name, Product Currency. If a mark of type “PL” is found, it is used in priority, otherwise a mark of type "NONE" is used if any. An exception will be raised if no PL Mark is found.

See PL Marks below for details.

If pricing parameter USE_MARKS = False, PricerFromDB retrieves pricer measures from the table trade_price.

See Trade Prices below for details.

 

1. PL Marks

PL Marks can be created using the scheduled tasks EOD_WAC / EOD_TD_WACfor weighted average cost liquidation purposes.

They can also be imported from a CSV file using Position & Risk > P&L Mark > Import Marksfrom the Calypso Navigator.

They can be viewed using Position & Risk > P&L Mark > P& L Mark Report from the Calypso Navigator.

Refer to Calypso Positions documentation for details on creating PL marks.

 

2. Trade Prices

You can import / set Trade Prices using the Trade Price Report (menu actionreporting.ReportWindow$PricerFromDB) - Help is available from that report.

Pricer measures stored in the trade_price table are retrieved by date.

See Trade Price Report for details.

 

Pricing Parameter PRICER_FROM_DB_EXCEPTION

True or False. Default is True.

When true, if you select multiple measures in the Pricing Sheet to be priced using PricerFromDB, and one is missing, the system raises an exception.

When false, these exceptions are not raised.

 

Pricing Parameter PRICE_INACTIVE_TRADE_FROM_DB

True or False. Default is False.

If True, PricerFromDB will price inactive, as well as active, trades from the database. That is, PricerFromDB will use pricer measure values stored in the trade_price table for the trade when pricing the trade.

If False, inactive trades are not priced from DB.

 

Pricing Parameter PRICE_TERMINATED_TRADE_FROM_DB

True of False. Default is False.

If True, the terminated trades show the custom prices / PL marks from DB. They show 0 otherwise.