Sei sulla pagina 1di 6

TH stores Purchase orders SAP Integration

TH Milk, Vietnam

====================================================================

1. Overview
The purpose of this document is to brief TH Stores Purchase Orders
interface with the SAP ECC system using SAP Process Integration.
The interface is required for daily PO cycle in SAP ECC system.

2. TH Stores
Each TH Store is supposed to send a tab delimited text files daily
containing the information to create Purchase Orders at SAP ECC system
side.

3. TH Milk SAP Integration from TH stores Using SAP PI

Connection of partner TH stores to TH Milk SAP System

Files from TH
Store will be
placed at FTP The processed
server in a file is sent to
specified the SAP
format. system.
====================================================================
SAP ECC system
TH STORES
SAP PI 7.1
Dy. Project Manager, CSC Ishita Mukherjee
Signature
Date 14-08-2010
Project Manager, CSC Ganesan B Iyer
TH store Signature
will create text files for PO daily Transaction called from incoming data
PI will read, validate and process the files
Date 14-08-2010

12th Aug 2010 Page 1 of 6


This is a unidirectional interface from TH Stores to SAP system.
A flat file will be sent from TH stores local machine to the FTP server using
an OS level FTP script. The representation File structure will be developed
as sending interface in SAP PI.
SAP PI is configured to pick the file from FTP server.

Once the file is picked, SAP PI will validate and send the processed file to
the SAP ECC 6.0 system using ABAP server proxies methodologies which in
turn call MM/FICO related transactions to post the data at ECC 6.0 system.

4. Flat file structure generated by TH stores


All the TH Stores will send a tab delimited text file for Purchase orders.
First line of the text file will be column headings of the file.
Second line onwards of the text file should contain the data records.
Each TH store will send 1 file containing daily Purchase order with multiple
lines in the file. 1st line will be column header and 2nd line onwards will be
the data records. The files have been named based on the following logic
XXXX_YYYYMMDD_StockReq.txt
XXXX Storage Location
DD Date
MM Month
YYYY Year
StockReq Representing the file is for creating purchase order

A sample text file format is attached.

1001_20101005_StockReq.txt

The file will have following columns.


S.No Column name Quantity
1 Store Number e.g. 1001
2 Supplying Plant e.g. 2300
3 Material SAP Material number
4 Qty Any numeric value
5 UOM Unit of measure
6 Delivery date YYYYMMDD format

12th Aug 2010 Page 2 of 6


Note: Any deviation in file format will cause error in PI or ECC 6.0
system.

5. Design and Configuration in SAP PI


1. Sender file communication channel named
CC_PODaily_THStores_SAP_File_Sender is configured to pick the file
from FTP server schedule to poll the FTP server every 60 seconds.
2. A message mapping MM_THStores_To_SAP_PODaily to convert source
data into target data format in SAP PI.
3. A receiver communication channel CC_PROXY_RECEIVER to send the
transformed data to SAP ECC system for further data posting.
4. Other mandatory PI objects are designed and configured in ESR and ID.

6. Interface flow and monitoring guide


1. TH Stores will put the file on the specified FTP server.
The FTP server address is same as PIP server (10.50.10.200)
The username/password of the TH Stores will be
thsuser/8df20b
and files will be kept on directory / THstores.

2. When the data is put on the FTP server on / THstores directory SAP PI
sender file communication channel will read the file and send it to SAP PI
integration engine for further processing.

Go to transaction SXI_MONITOR press F8 and check if the data is on


successful state.

12th Aug 2010 Page 3 of 6


In the next screen you will find a black flag for your message. Black
flag is symbol of success.

All the successful read file are archived on the folder


/home/THstores/success on application server of PI server and failed
files will be saved on /home/THstores/fail

If you are not able to find the data here go and check adapter engine
monitoring.

Step1. Go to Tcode SXMB_IFR

12th Aug 2010 Page 4 of 6


Step2. Click on Runtime Workbench give your user and password
Step3. Go to component monitoring—select adapter engine
monitoring and click on communication channel monitoring. – Give the
name as CC_PODaily_THStores_SAP_File_Sender and click on Use
filter button.
Step4. It will log the information if something goes wrong in file
processing from FTP server.

3. When the data is successful in PI check the transaction


SXI_MONITOR in SAP ECC system. This should also be successful.
Once the data is successful in ECC systems ABAP server proxy will
check the table ZTHSTORES for PO type (EKKO-BSART),
Purchasing Org. (EKKO-EKORG),Purchasing Group (EKKO-EKGRP)
and Company code (EKKO-BUKRS).
In the source file, user will give these inputs: Store Number
(EKPO-LGORT), Supplying Plant (EKKO-RESWK), Material (EKPO-
MATNR), Quantity (EKPO-MENGE), UOM Order Unit (EKPO-MEINS),
Delivery Date (EKET-EINDT)
From the parameter Supplying Plant in the source file, map with the
field LFA1-WERKS, we get the Vendor (LFA1-LIFNR) to input into
Vendor of Purch.Order (EKKO-LIFNR).From the parameters Material,
Sloc in the source file, map with the fields MARD-MATNR and
MATNR-LGORT, we get the Plant (MARD-WERKS) to input into Plant

12th Aug 2010 Page 5 of 6


of Purch.Order (EKPO-WERKS).Purch.Order Document Date (EKKO-
BEDAT) is the current creation date .

4. In real time a spool request is generated titled THSTORE_PO with


user name BASIS. We can find the spool in the transaction SP01. The
spool will display status of the generated Purchase Order.
5. In case of any error in the processing table ZTHSTORES_PO is
updated with error data records of the file.
6. To reprocess the data go to tcode ZTHSTORE_PO and select the data
to be reprocessed. If data records needs to be changed , change the
record in table ZTHSTORES_PO using transaction SM30 and execute
the report.

====================================================================

Dy. Project Manager, CSC Ishita Mukherjee


Signature
Date 05-10-2010
Project Manager, CSC Ganesan B Iyer
Signature
Date 05-10-2010
Created By Amitanshu Deep
Date 05-10-2010
Document References THM_BBP_V1.0.doc

12th Aug 2010 Page 6 of 6

Potrebbero piacerti anche