Enterprise Resource Planning Blogs by Members
Gain new perspectives and knowledge about enterprise resource planning in blog posts from community members. Share your own comments and ERP insights today!
cancel
Showing results for 
Search instead for 
Did you mean: 
grigoriy_babitskiy
Active Contributor

File interface is similar to Datafeed, but here we will use files instead of connection to internet.

All cutomizing will be done following this path:

SAP Customizing Implementation Guide -> Financial Supply Chain Management -> Treasury and Risk Management -> Basic Functions -> Market Data Management -> File Interface -> ...


All Data Processing will be done following this path:

SAP Menu -> Accounting -> Financial Supply Chain Management -> Treasury and Risk Management -> Basic Functions -> Market Data Management -> File Interfaces -> ...

Configuration.

But now let's make some configuration in order file interface to work.

Define Source of Market Data and Conversion Codes

SAP Customizing Implementation Guide -> Financial Supply Chain Management -> Treasury and Risk Management -> Basic Functions -> Market Data Management -> File Interface -> Define Source of Market Data and Conversion Codes (tr. SM30 -> V_VTBFFFT)

First of all we create Data Provider ID for the file interface.

TIP: if you use the same data provider for File Interface and for Datafeed - then you have to configure both of them similar to each other, otherwise you can get error like this "No data source defined for datafeed name". In our case we have the same 4 fields: Data Provider, Description, Quotation source/Comm(05), Quotation Source/Comm(06).

Create Tables for Code Conversion

SAP Customizing Implementation Guide -> Financial Supply Chain Management -> Treasury and Risk Management -> Basic Functions -> Market Data Management -> File Interface -> Create Tables for Code Conversion (tr. SM30 -> V_MDUCV)

Creation of Tables for code conversion is similar to the same operation in Datafeed configuration TRM Market Data Management: Datafeed: Configuration.

Before creating tables for Code Conversion, the tables are empty. After creating tables - it will be filled with SAP data. All you need is to map SAP Data with External Providers' data.


Start transaction. Select required conversions. Execute operation.

Press "Yes" button.

The information dialog appears.

Convert Codes for Exchange Rate Types

SAP Customizing Implementation Guide -> Financial Supply Chain Management -> Treasury and Risk Management -> Basic Functions -> Market Data Management -> File Interface -> Currencies -> Convert Codes for Exchange Rate Types (tr. SM30 -> V_MDUCV)


Now we can check conversion table and map SAP data with external data.

If you need you create conversion table for other data, do it!

That's all with configuration.

Processing market data

SAP Menu -> Accounting -> Financial Supply Chain Management -> Treasury and Risk Management -> Basic Functions -> Market Data Management -> File Interfaces -> ...

TBDN - Generate Request List

Befor entering market data we need to prepare files. In this case tr. TBDN can help us.

Indicate file name where structure of file will be created.

Put a checkmark in checkbox field "PC download".

Indicate data provide name.

Select Instrument class to fill our file.

If you use Selection fields, you can limit SAP data to be passed into file.

In our case i want to create file for entering Refinance rate only.

Execute transaction.

Select is done.

Select data and press "Save" button.

Press "Yes" button.

If you didn't create Converstion tables you'll get this information dialog.

File is created

The structure is the following:

## - comments.

90 tag - is for data provider id.

01 tag - line for currencies' data.

02 tag - line for securities' data.

03 tag - line for interest rates' data.

04 tag - line for indices' data.

05 tag - line for commodities' data.

06 tag - line for CPE commodities' data.

07 tag - line for Commodity Forward Rate data.

08 tag - line for Derivative Contract Specification data.

09 tag - line for basis spreads' data.

10 tag - line for credit spreads' data.

21 tag - line for swap forwards' data.

30 tag - line for universal volatility item's data.

31 tag - line for currency volatilities' data.

32 tag - line for security volatilities' data.

33 tag - line for interest volatilities' data.

But actually the file is not full.

The full structure is the following:

For tags starting from 01 to 33 the line consists of the following data. Data is represented like a strings without any separators. The seprarotr is the length of field.

FIeld num.Field nameSize in charsStructure and fieldDescriptionRequired field (R) / Empty (E)
1SCLASS2VTB_MARKET-SCLASSDatafeed: Instrument Class (tag id)R
2RKEY120VTB_DFANS-RKEY1Datafeed: Key 1R
3RKEY220VTB_DFANS-RKEY2Datafeed: Key 2

R (Cat. 01)

R (Cat. 02)

E (Cat. 03)

E (Cat. 04)

E (Cat. 07)

4SINSTRUMNT15VTB_DFANS-SPRPTYDatafeed: Market data: Instrument property

R (Cat. 01) Rate Type

R (Cat. 02) Volatility Type

E (Cat. 03)

R (Cat. 04)

R (Cat. 05) Commodity Quotation Type

R (Cat. 06) Commodity quotation type

R (Cat. 07) Commodity Quotation Type

5DDATE8VTB_DFANS-DDATEDatafeed: Value date in SAP format

R Value Date (Format: DDMMYYYY)

R (Cat. 05 - 07) Quotation Date (Format: DDMMYYYY)

6TTIME6VTB_DFANS-TTIMEDatafeed: Time of value (SAP format)E Time of Value Data (Format: HHMMSS)
7VALUE20VTB_DFANS-VALUEDatafeed: Value of requested propertyR
8CURRENCY20VTB_DFANS-CURRENCYDatafeed: Currency key

E (Cat. 01) Currency D

R (Cat. 02)  Data description

E (Cat. 03)

E (Cat. 04)

E (Cat. 05)  Notation Currency Unit

E (Cat. 06) Notation Currency Unit

E (Cat. 07) Notation Currency Unit

9FFACT7VTB_DFANS-CFFACTDatafeed: Factor for units of from-currency

R (Cat. 01) Ratio for Units of

E (Cat. 02) FROM currency

E (Cat. 03)

E (Cat. 04)

10TFACT7VTB_DFANS-CTFACTDatafeed: Factor for units of to-currency

R (Cat. 01) Ratio for Units of

E (Cat. 02) FROM currency

E (Cat. 03)

E (Cat. 04)

11MKIND5VTB_DFANS-MKINDDatafeed: Price notation for security pricesE
12SSTATS2VTB_MARKET-SSTATSDatafeed: Status of market dateE
13ERROR80VTB_MARKET-ERRORDatafeed: Error messageE

Example of complete file with information. You can also find this file in attachment to this article.

TBDM - Import

Now we can import market data.

  • Input:
    • Upload: Tell transaction you want to upload file from PC, or from server.
    • File name: file with market data. For PC you can use search help to enter file name. For server you can use transaction AL11 to copy path of file. File path is similar to /usr/sap/trans/log/log.txt
    • Exchange rates: indicate whether you will upload direct or indirect quatation.
  • Data provider:
    • Manual entry:
      • Data provider: Indicate data provider if you use manual entry.
    • Generate automatically from file: if you use this option then data provider is take from file using 90 tag.
  • Error file
    • Download: Tell transaction you want to download error file to PC, or to the Server.
    • Generate error file
      • File name: indication file where errors will be saved.
  • Output control:
    • Test run
    • Output list of results: save all data, only errors, only correct results.
    • Layout: layout of data.

Fill selection screen and execute transaction.

That's how you can upload market data into SAP using FIle interface.

More information about Market data management - Index.

3 Comments
Labels in this area