conquering the unknown world between two sap … the unknown world between two sap erp systems ......

53
Conquering the unknown world between two SAP ERP systems Philipp Liegl @ecosioHQ 1

Upload: nguyennhan

Post on 07-Mar-2018

257 views

Category:

Documents


10 download

TRANSCRIPT

Page 1: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Conquering the unknown world between two SAP ERP systems

Philipp Liegl@ecosioHQ

1

Page 2: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

whoami

2

Page 3: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Here be dragonsA journey between two SAP systems

3

SAP

SAP

Page 4: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Electronic Data Interchange is fully automatedBut until it works, it is a people business

4

SAP Project Manager“We must deliver on

time and budget”

SAP Consultant“I must adhere to the

business blue print and get the customizing right”

ABAP programmer“*@%#& them and their

constantly changing requirements”

SAP Basis“The instance is too small,I told them a million times”

Car manufacturer“Please call global service

helpdesk for further assistance”

Customer“We must go live on xyz

by all means”

Supplier“We not have time

for EDI now, please comeback in 6 months”

EDI service provider“SAP team, customer,

suppliers and OEMs, please provide commitment”

Page 5: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Agenda

The roots of electronic data interchange (EDI)

EDI in detailIdentificationRepresentationData Exchange

EDI and SAP

5

Page 6: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

The Berlin Airlift – the roots of Electronic Data Interchange

6

1948

Page 7: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Goods identification and advanced shipping notifications

7

„Information about the transported goods is as important as the goods themselves“

-- Edward Guilbert

Page 8: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

What is Electronic Data Interchange exactly?

• Not a „single“ technology – rather a concept

• The exchange of structured electronic documents between software systems of different companies with minimal human intervention.

8

Supplier

ERP system A

Manufacturer

ERP system B

Order

Advanced shipping notification

Goods

Page 9: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

The necessity of a unique identification

9

Schraube

screw

tire-bouchon

tornillo

vite

螺丝 [螺絲] śruba

Page 10: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

The three main requirements of electronic data interchange

Unique identification of exchanged products and services as well as the participating partners

Unique representation of exchanged information

Exchange procotol, which guarantees delivery of electronic documents

10

Page 11: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Identification by brandMainly for customers and marketing purposes

11

Page 12: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Machine processing without unique identification. How many companies do you see?

12

ecosio InterCom GmbH

Leoprechtingstr. 3281739 München

Deutschland

ecosio InterCom GmbH

Leoprechtingstraße 32

81739 München

ecosio InterCom GmbH

Leoprechtingstrasse 32

81739 Munich

Germany

ecosio InterCom GmbH

Leoprechtingstr. 32

81739 Muenchen

Allemagne

Page 13: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Identification numbers to the rescueWe simply take SAP debtor or creditor numbers

13

Page 14: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Do not do that. Ever.

14

Page 15: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Necessity of unique identification

• Companies

• Products and services• Transport units

• EDI addresses

Solution

• Use of a common code scheme, which is maintained by a central administration body

• Prevents use of duplicate codes and guarantees global uniqueness

15

Page 16: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Where to take these “unique” numbers from?

16

Bilateral agreement between partners

• Global uniqueness• Very common in retail• Unique identification of partners (GLN),

products (GTIN), pallets (SSCC), etc.

• Global uniqueness• Unique identification of partners only (DUNS no.)

• No global uniqueness• Often used in industry (e.g., BMW-AG,

JLR, etc.)• Customer/supplier material numbers

Page 17: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Global Location Numbers (GLN)Unique identification of business partners and EDI mailboxes

17

N1 N2 N3 N4 N5 N6 N7 N8 N9 N10 N11 N12 N13

GS1 company prefix(7 – 9 digits)

location reference check digit

Structure

Example

Company XYZBranch 1

Company XYZBranch 2

GLN: 9 0 1 2 3 4 5 0 0 0 0 0 4

GLN: 9 0 1 2 3 4 5 1 0 0 0 0 1

Page 18: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Tired?

18

20166.062 billion cans sold

Page 19: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

GTIN – Global Trade Item Number

• GS1 number for the unique identification of trade items

• A GTIN has 8/12/13/14 digits

• GTIN is based on the GLN of a company

• GTINs are exchanged using master data exchange concepts (e.g., GDSN - Global Data Synchronization Network)

19

Page 20: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

SSCC – Serial Shipping Container Code

Unique identification of transport units

20

Sender:ecosio InterCom GmbHLeoprechtingstr. 3281739 München

SSCC:

GTIN:

Production date: Lot:

3 426030462 1234567 8

42 6030462 999 4

15.12.2016 4711A3

NVE

Page 21: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Why is the transport label in conjunction with EDI so important?

21

Pallet 1SSCC: 342603046212345678GTIN: 4260304629994Delivered units: 10

Pallet 2SSCC: 342603046212345685GTIN: 4260304629987Delivered units: 20

Pallet 3SSCC: 342603046212345692GTIN: 4260304629970Delivered units: 30

Sandwich pallet:Master SSCC: 342603046212345104

Page 22: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Representation

22

import java.math.BigDecimal;

import lombok.Data;

//Generates toString, equals, hashCode and //all getters and setters@Datapublic class Product {

private String id;private String name;private BigDecimal price;

}

import com.ecosio.entities.Product;

import java.math.BigDecimal;import java.util.ArrayList;import java.util.List;

public class ProductProcessor {

List<Product> productList = new ArrayList<>();

private void loadProducts() { Product p = new Product();p.setId("4711");p.setName("Some name");p.setPrice(new BigDecimal("34.50"));productList.add(p);

}}

Page 23: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Your nice internal data structures?

23

Page 24: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Unambiguous representation of exchanged information is an important prerequisite for EDI

Application-to-application communication requires a standardized exchange format, which sender and recipient understand

24

Sender‘sERP system

Recipient‘sERP system

EDIFACT EANCOM D01B DESADV

Sender‘sERP system

Recipient‘sERP system

Converter

EDIFACT EANCOM D01B DESADV

VDA 4913 dispatch advice

Page 25: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Data exchange formats

25

VDAFlat-Text

EDIFACT

EDIFACT EANCOM

XMLcXML CSV

IDocTRADACOM GS1 XML

openTRANS

proprietaryformat

ZUGFeRD

UBL

JSON

ANSI ASC X12

Page 26: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

A few standardization organizations

26

A Joint Publication

ECM RecommendationPart 0 (ECM) Version 2.0, issued Aug. 2009 Replacements: Version 1.0

VDA 4965 – Part 0 Version 3.0, issued Jan. 2010 Replacements: Version 2.0

A Joint Publication

ECM RecommendationPart 0 (ECM) Version 2.0, issued Aug. 2009 Replacements: Version 1.0

VDA 4965 – Part 0 Version 3.0, issued Jan. 2010 Replacements: Version 2.0

Page 27: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Conversion (or mapping) – translating between different formats

27

Sender

ERP system A

Recipient

ERP system B

Proprietary format A

Proprietary format B

ConversionRouting

EDI formate.g., VDA, EDIFACT, etc.

ConversionRouting

Page 28: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Motivation for an EDI standard

28

A

B

CD

E

A

B

CD

E Standardformat

Page 29: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Examples for EDI standards

• UN/EDIFACT delimiter based

• ANSI ASC X12 delimiter based• VDA EDIFACT-based and fixed-length

• ODETTE based on EDIFACT

• EANCOM EDIFACT subset

• cXML XML

• openTRANS XML• IDoc XML or fixed-length, rather an exchange format, than

• … an EDI standard

29

Page 30: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

EDIFACT example for an ORDERS

30

UNA:+.? 'UNB+UNOA:3+01234567890123:14+01234567890124:14+130516:1552+MSGNR111++++++1'UNH+1+ORDERS:D:96A:UN:EAN008'BGM+220+DOCNR1234'DTM+137:20130519:102'DTM+2:20130520:102'NAD+BY+5682357469542::9'NAD+DP+3839204839274::9'NAD+SU+0293083940382::9'LIN+1++1122334455667:EN'QTY+21:11.00:PCE'UNS+S'CNT+2:1'UNT+12+1'UNZ+1+MSGNR111'

Page 31: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

UNB-SegmentInterchange Header

31

UNA:+.? 'UNB+UNOA:3+01234567890123:14+01234567890124:14+130516:1552+MSGNR111++++++1'

Used charset

UNOA = UN/ECE level A equals ISO 646 – with some exceptionsUNOB = UN/ECE level Blike UNOA with less exceptionsUNOC = UN/ECE level Cequals ISO-8859-1UNOD = UN/ECE level Dequals ISO-8859-2UNOE = UN/ECE level Eequals ISO-8859-5 (cyrillic)UNOF = UN/ECE level Fequals ISO 8859-7 (latin/greek)etc.

Sender of message

Receiver of message

Date and time

Interchange ID

Test indicator

Page 32: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

XML-Standards

• Became increasingly popular by mid/end of the nineties of the last century

• Distinction between markup and content• Larger memory footprint than delimiter based or fixed-length formats

• Please never say “it is human-readable”

32

<document:MessageHeader><document:MessageReferenceNumber>1</document:MessageReferenceNumber><document:MessageType>DELFOR</document:MessageType>

</document:MessageHeader><document:BeginningOfMessage><document:DocumentNameEncoded>241</document:DocumentNameEncoded><document:DocumentNumber>000000108</document:DocumentNumber>

</document:BeginningOfMessage>

Page 33: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Memory footprint comparisonDoes it matter?

33

VW DELFOR (EDIFACT)

Internal converter format(XML)

SAP IDoc DELFOR(XML)

12 KB 120 KB(10 x)

58 KB(~ 5 x)

UN/EDIFACT IDoc XML

Keep in mind that routing and storage do not come for free!

Page 34: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Typical message types in the retail industry

34

Supplier Buyer

Order (ORDERS)

Order Change (ORDCHG)

Order Response (ORDRSP)

Dispatch Advice (DESADV)

Goods

Receipt Advice (RECADV)

Invoice (INVOIC)

Price Catalog (PRICAT)

https://blogs.sap.com/2017/09/05/realizing-procurement-edi-processes-with-ansi-asc-x12-edifact-and-idocs/

Page 35: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Typical message types in the automotive industry

35

Tier 1 supplier OEM

JIT forecast (DELJIT)

JIS forecast (DELJIT)

Goods

Receipt Advice (RECADV)

Invoice/Credit note (INVOIC)

Forecast (DELFOR)

ASN (DESADV)

Funct. Ack (CONTRL)

https://blogs.sap.com/2017/08/17/realizing-automotive-edi-processes-with-vda-edifact-ansi-odette-and-idocs/

Page 36: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Routing of EDI messages

Each EDI message must be able to answer the following four questions:

• Who are you?• Where do you come from?

• Where do you want to go?

• Are you a test message?

Additional questions• What is your unique ID?

• When have you been created?

36

Page 37: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Data exchange

37

IBM 360 in action at Volkswagen

Page 38: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Data transport today using dedicated protocols

• AS2

• SFTP, FTPS

• OFTP2

• OFTP1 (not recommended, as ISDN will soon be switched off)

• X.400 (can be quite costly)

• RESTful Web Services• Usually for the last mile between ERP and service provider, e.g., Ariba, ecosio, etc.

• SOAP/WSDL• Quite verbose and rigid – cf. WS-Death Star

• SMTP• Only when sender authenticates at the SMTP

• VAN• Old term for dedicated EDI networks. Some still exists, e.g., ANXeBusiness, ENX, JNX, etc.

38

Page 39: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Data transport – usually a four corner model is used

39

Company ASAP

ERP system

Service provider A

Routing

Delivery andFetch

Service provider B

Company BMS Dynamics ERP system

Delivery andFetch

Page 40: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Rule of thumb – be process compliant or prepare for a rough ride

40

Page 41: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Ready? Let’s go:

41

Page 42: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

SAP and EDI

42

SAP ERP EDIservice provider

EDIFACT,VDA, etc.IDoc

inbound

outbound

Partner

Page 43: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

IDoc – Intermediate DocumentProvide XML Schema and documentation to the EDI service provider

43

WE60

Page 44: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

SAP and EDIYes, there are dragons

44

Customer‘s domain

SAP-System

Business partner

Business partner

Business partner

Business partner

Business partner

Business partner

EDIFACT D96A, X.400Telekom

VAN 1

VAN 2etc.

UBL-XML, SFTP

ODETTE DELFOR, SMTP

CSV, X.400

EANCOM D98B, AS2

VDA 4913, OFTP, ISDN

AS2server

X.400box

SFTPserver

etc.

EDIconverter

Performsmappings

Generates andconsumes IDocs

Page 45: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Typically a service provider is hired, who tames the „dragons“

45

Import-/export-interface

Business partner

Business partner

Business partner

Business partner

Business partner

Business partner

all business partners,protocols and formats

onemanaged

connectionEDI service

provider(routing,

conversion)

ERP system

Page 46: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Closer integration using an API – EDI functionality as native feature of the ERP system

46

ERPEL Add-On

Business partner

Business partner

Business partner

Business partner

Business partner

Business partner

all business partners,protocols and formats

SAP System

ERPEL API

Page 47: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

EDI minefield

47

Page 48: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Outbound Message routing, based on EDI_DC40 informationOften unique sender and receiver identification is missing

48

<DESADV01><IDOC BEGIN="1"><EDI_DC40 SEGMENT="1">

<TABNAM>EDI_DC40</TABNAM><MANDT>100</MANDT><DOCNUM>0000000046615484</DOCNUM><DOCREL>700</DOCREL><STATUS>30</STATUS><DIRECT>1</DIRECT><OUTMOD>2</OUTMOD><IDOCTYP>DESADV01</IDOCTYP><MESTYP>DESADV</MESTYP><SNDPOR>SAPP01</SNDPOR><SNDPRT>LS</SNDPRT><SNDPRN>P01CLNT100</SNDPRN><SNDLAD>7844849473214</SNDLAD><RCVPOR>ECOSIO</RCVPOR><RCVPRT>KU</RCVPRT><RCVPFC>SP</RCVPFC><RCVPRN>1005101</RCVPRN><RCVLAD>95412163215412</RCVLAD><CREDAT>20170822</CREDAT><CRETIM>064159</CRETIM><SERIAL>20170822064159</SERIAL>

</EDI_DC40>...

</DESADV01>

oftenmissing

Page 49: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Example Daimler

49

UNA:+.? 'UNB+UNOA:1+SUPPLIER-XYZ+O0013007313MB006000+171005:1638+5571'UNH+80035375+DESADV:D:96A:UN'

Receiver identification on aper-factory basis must be retrieved from the exported IDoc

Page 50: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Where to re-key?

50

SAP Serviceprovider Daimler

Ship-To: GLC Germersheim4711

GLC GermersheimO0013007313MB006000

DESADVD96AIDoc

• The originator must re-key (= the SAP)

• Do not re-key in the mapping on the service provider’s side (maintenance nightmare)

Page 51: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Wrap up

• EDI is a prerequisite for efficient inter-organizational processes

• Large enterprises and medium-sized companies need EDI to run their business

• SMEs must comply with the EDI requirements

• However, they may benefit from EDI as well

• EDI converter

• Four corner-model communication• SAP may serve as target/source for EDI processes

• EDI in SAP is not turn-key – some configuration is always necessary

51

Page 52: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

52

ecosio InterCom GmbHLeoprechtingstr. 3281739 München, GermanyTel: +49 89 6066 6456

ecosio GmbHWiedner Hauptstraße 521040 Wien, AustriaTel.: +43 1 996 21 06

Email: [email protected]: http://www.ecosio.comTwitter: @ecosioHQ

Page 53: Conquering the unknown world between two SAP … the unknown world between two SAP ERP systems ... EDIFACT example for an ORDERS 30

Image credits

SAP Logo: SAP SE, http://www.sap.com, © 2017 SAP SE oder ein SAP-Konzernunternehmen.World map: http://www.gallery.oldbookart.com/ Map of Germany, landing C-17, care package, planes at Tempelhof, tower of Babel, UN security council, IBM 360 at Volkswagen, Minen-Mines: Wikimedia CommonsNimm2, www.nimm2.atCompany logos: https://www.fastcodesign.com/3034007/whats-the-difference-between-a-logo-and-a-symbol Loading ramp: http://www.butt.deGoods on truck: http://www.mvn.chBorder control: http://www.zimbio.com/pictures/n56225uJLV6/Customs+Border+Protection+Screen+Travelers/3etDcuVTplj Icons: Freepik - http://www.flaticon.comRed Bull: own pictureRough road: https://www.flickr.com/photos/childplay/7852066624

53