Importing a File: Transaction data

TXT file

You have a TXT file on your PC with the stock prices and the difference from the previous day for company XXX on the following days:

XXX_13.01.1997_110.50_-2.00

XXX_14.01.1997_112. 00_1.50

XXX_15.01.1997_115. 00_3.00

XXX_16.01.1997_113. 00_-2.00

XXX_17.01.1997_112. 50_-0.50

The underscore ( _) between the fields in the lines symbolizes the TAB character that separates the fields.

You want to import this data into aspect 004 ( stock prices ). The aspect contains the characteristics FIRMA ( corporation ) and BOTAG ( trading day ) and the key figures AKURS ( stock price ) and DIFFZ ( difference ).

You create a sender structure KURSE and enter the following data:

Aspect

004

Conversion

0

Field name

Ref. table

Field name

Type

Length

Dec. places

FIRMA

CF004

Corporation

C

8

0

BOTAG

CF004

Trading day

D

8

0

AKURS

CF004

Com. stock

P

8

2

DIFFZ

CF004

Difference

P

8

2

With the entry of a field name and a reference table, the other fields are automatically derived from the reference table. You generate the sender structure and then maintain the transfer rules. In addition to the characteristic values, that are maintained in the sender structure, transfer rules have to be maintained for the fixed characteristics VERSIO (version), YEARB (fiscal year), PERIO (period), and PLACTI (Plan/Actual indicator).

Recv. field

Assign. rule

Sender field

Offset

Length

Constant

VERSIO

SET

VERSIO

   

0

YEARB

MOVE

BOTAG

0

4

 

PERIO

MOVE

BOTAG

4

2

 

FIRMA

MOVE

FIRMA

0

0

 

BOTAG

MOVE

BOTAG

0

0

 

PLACTI

SET

     

0

You save the transfer rules and then maintain the selection data for importing the file.

To carry out a test run of the transfer, enter the following data:

Field

Entry/Selection

Sender structure

SHARE PRICE

File

Path in which the file can be found. For example d:\file\ablexcel\share.txt

File system

Presentation server

Editing

Display file

Display sender record -field assignment

File type

TXT format

Number format

Type P

Decimal point

Data format

ASCII

Date format

DD.MM:YYYY

Then you can execute the program.

If the test data is satisfactory, you can select Data transfer and execute the program again.

CSV files

In CSV files the fields of a record are separated with a semicolon.

Note Note

If you are working with an English version of MS Excel, note that the fields are separated with a comma. In this case, save the file as a text file. When importing the file, select file type Text file with field separator instead of CSV format and enter a comma (,) as the separator.

End of the note.

XXX,13.01.1997,110.50,-2.00

XXX,14.01.1997,112.00,1.50

XXX,15.01.1997,115.00,3.00

XXX,16.01.1997,113.00,-2.00

XXX,17.01.1997,112.50,-0,50

To execute this example with a CSV file, you would basically set the parameters as for a TXT file, with the exception of the path and file type.

Text file

To transfer a text file without an editing character (neither a +/- sign nor a decimal point) with this sender structure and these transfer rules, the file to be imported must read as follows:

XXX199701130001105000000200-

XXX199701140001120000000150

XXX199701150001150000000300

XXX199701160001130000000200-

XXX199701170001125000000050-

(FIRMA BOTAG AKURS DIFFZ)

This format is given by the specified length and decimal places in the sender structure.

In order to execute this example using a text file without editing characters, the parameters must basically be set in the same way as a TXT file, with the following exceptions:

Field

Entry/Selection

File type

Text file

Number format

No editing characters

Date format

YYYYMMDD

See also:

Importing a File