cancel
Showing results for 
Search instead for 
Did you mean: 

Reg:Seeburger BIC

Former Member
0 Kudos

Hello All,

I am working form xml to EDIFACT Map.based on the number of OrderReason in the input file we must genrate the FTX Segment in the output.

For Example:

If the inputfile looks like:

<OrderReason>

<OrderReasonCode>RSRJCT</OrderReasonCode>

<OrderReasonDescription>Info The order has been rejected by HP-RSAP</OrderReasonDescription>

</OrderReason>

<OrderReason>

<OrderReasonCode>E9850A</OrderReasonCode>

<OrderReasonDescription>Error Price is different from that in HP</OrderReasonDescription>

</OrderReason>

The output must be:

FTXACD++RSRJCT'

FTXAAO++Info The order has been rejected by HP-RSAP'

FTXACD++E9850A'

FTXAAO++Error Price is different from that in HP'

The Condition i was written was not incrementing:

//FTX ACD

if existSourceField("B2BGatewayDoc.Document.ServiceContent.POConfirmationHeader.OrderReason.OrderReasonCode:value") = true

copy "ACD" to UNB.SG0.UNH.FTX:4451;

copy B2BGatewayDoc.Document.ServiceContent.POConfirmationHeader.OrderReason[lvORDERREASONCOUNTER%].OrderReasonCode:value to UNB.SG0.UNH.FTX:C108.4440;

endif

//FTX AAO

if existSourceField("B2BGatewayDoc.Document.ServiceContent.POConfirmationHeader.OrderReason.OrderReasonDescription:value") = true

copy "AAO" to UNB.SG0.UNH.FTX:4451;

copy B2BGatewayDoc.Document.ServiceContent.POConfirmationHeader.OrderReason[lvORDERREASONCOUNTER%].OrderReasonDescription:value to UNB.SG0.UNH.FTX:C108.4440;

endif

lvORDERREASONCOUNTER%=lvORDERREASONCOUNTER%+1;

Can,any one guide me.

Accepted Solutions (0)

Answers (2)

Answers (2)

srikanth_srinivasan3
Active Participant
0 Kudos

Hi

Question:

1) Why do you want to add a counter, cos your input message XML tags doesnt seem to contain any number?

2) In case, your XML tags could have counters, then u can frame the source elements XPATH in a local variable & then use the value in COPY funtion.

Remember, you are using IF statement NOT a loop.

-

Srikanth Srinivasan

Former Member
0 Kudos

Hello,

Any one can guide me reg this i will sent my input file,expected output file and map,version of seeburger i was using is (6.3.2).

Thanks,

Kishore

shweta_walaskar2
Contributor
0 Kudos

Hello,

Please excuse if I am not able to understand it correctly.

But what I can understand is,you are trying to change Seeburger BIC mapping.

Is this really required?Your purpose can be solved by creating a Graphical mapping of XML to EDIFACT XML,where you can create multiple FTX segments using duplicate subtree and apply mapping logic.

Then this EDIFACT XML can be converted to EDIFACT using Standard Seeburger mapping.

This is how we handle such requirements.We don't change Seeburger mapping for such customer specific requirements.

Please let me know if this makes sense.

Regards,

Shweta

Former Member
0 Kudos

Hello Shweta,

Thanks for the reply.Can plz explain me in clear...In the target structre paticular FTX is occuring for 99 times.Is there any need of duplicating it.

Thanks,

Kishore

Edited by: kkandregula on Jun 23, 2010 2:20 PM

shweta_walaskar2
Contributor
0 Kudos

Hello Kishore,

Even though the occurence os FTX is 0..99 ,you need to use duplicate subtree to have two FTX segments,one for ACD and other for AAO.

You can map this like:

Map UNH(parent of two FTX segments) -> OrderReason

For ACD,

Hardcode ACD in corresponding field of first FTX segment

Map OrderReasonCode to corresponding field in first FTX segment

For AAO

Hardcode AAO in corresponding field of second FTX segment

Map OrderReasonDescription to corresponding field in second FTX segment.

This should work.Only doubt is,it shouldn't give output as:

FTXACD++RSRJCT'

FTXACD++E9850A'

FTXAAO++Info The order has been rejected by HP-RSAP'

FTXAAO++Error Price is different from that in HP'

Please check and let us know.

Thanks.

Regards,

Shweta

Former Member
0 Kudos

Hello Shweta,

Thanks once again .If in the input file we are getting more than 2 OrderReason means what we have to do?

Thanks,

Kishore

shweta_walaskar2
Contributor
0 Kudos

Hello Kishore,

This logic is not specific to two OrderReason nodes only.

I suggested to create 2 FTX segments because you have 2 qualifiers ACD and AAO.

as you are mapping OrderReason to UNH segment,same number of UNH segments should be created as many OrderReason nodes are there.

Please let me know if you need further details.

Regards,

Shweta

Former Member
0 Kudos

Hello Shweta,

As u have specifed i have duplicated the ftx and written the cond as u have specified,the output i was getting:

FTXACD++RSRJCT'

FTXDIN++RameshSP10RameshSP10Ramesh:RameshSP10RameshSP90'

FTXACB++455'

FTXAAO++Info The order has been rejected by HP-RSAP'

In this case also i am getting first OrderReasonCode and first OrderReasonDescription and the output order is also wrong.Can u give any suggestion reg this...

Thanks,

kk

shweta_walaskar2
Contributor
0 Kudos

Hello Kishore,

Now I see you have 4 qualifiers: ACD, DIN, ACB ,AAO.

From where do you get these Qualifiers?I can't see them in your input structure.

You have to use duplicate subtree for FTX segment same number of times as the number of qualifiers.

Please send your input file and expected output file

Regards,

Shweta

Former Member
0 Kudos

Hello Shweta,

The input file :

<?xml version="1.0" encoding="ISO-8859-1" ?>

<B2BGatewayDoc>

<Document>

<ServiceHeader>

<Protocol>

<Sender>003897733</Sender>

<Receiver>544759087</Receiver>

<MsgType>3A4MG2</MsgType>

<ReferenceNumber>1</ReferenceNumber>

<InstanceIdentifier>455</InstanceIdentifier>

<PipVersion>V02.00</PipVersion>

</Protocol>

</ServiceHeader>

<ServiceContent>

<FromRole>

<ContactName>HP CO OM</ContactName>

<EmailAddress>GOPALKRISHNANV</EmailAddress>

<TelephoneNumber>65-67271815</TelephoneNumber>

</FromRole>

<ToRole>

<ContactName>YANG MINGJIN(IRENE</ContactName>

<EmailAddress>IRENE.YANG-ASIA.COM</EmailAddress>

<FaxNumber>021-24016684</FaxNumber>

<TelephoneNumber>021-24016753</TelephoneNumber>

</ToRole>

<POConfirmationHeader>

<PONumber>SP30-60659-S</PONumber>

<RequestingDocumentDateTime>20100525T120000.000Z</RequestingDocumentDateTime>

<DefaultSetID>HAERFZ</DefaultSetID>

<SoldTo>544759087</SoldTo>

<SpecialInstruction>RameshSP10RameshSP10RameshSP10RameshSP10RameshSP10RameshSP10RameshSP70RameshSP10RameshSP10RameshS100RameshS110</SpecialInstruction>

<ClaimCode>90198816</ClaimCode>

<PartialShip>Y</PartialShip>

<ReceiverAddress />

<SpecialDeliveryInstruction>RameshSP10RameshSP10RameshSP10RameshSP10RameshSP10RameshSP10RameshSP70RameshSP10RameshSP90RameshS100</SpecialDeliveryInstruction>

<OrderStatusCode>R</OrderStatusCode>

<OrderReason>

<OrderReasonCode>RSRJCT</OrderReasonCode>

<OrderReasonDescription>Info The order has been rejected by HP-RSAP</OrderReasonDescription>

</OrderReason>

<OrderReason>

<OrderReasonCode>E9850A</OrderReasonCode>

<OrderReasonDescription>Error Price is different from that in HP</OrderReasonDescription>

</OrderReason>

</POConfirmationHeader>

<POConfirmationLineItems>

<HPOrderNumber>999999999999</HPOrderNumber>

<AckDateTime>20100611T030920.000Z</AckDateTime>

<LineItemClaimCode>90198816</LineItemClaimCode>

<LineItemNumber>1</LineItemNumber>

<BuyerLineItemNumber>001</BuyerLineItemNumber>

<HPProductNumber>51645AA</HPProductNumber>

<ProductDescription>NLA - REORDER 51645BA (40)</ProductDescription>

<RequestedProductQuantity>40</RequestedProductQuantity>

<ProductQuantity>40</ProductQuantity>

<RequestedDeliveryDate>20100630</RequestedDeliveryDate>

<RequestedProductUnitPrice>167.44</RequestedProductUnitPrice>

<ProductUnitPrice>160.00</ProductUnitPrice>

<RequestedCurrencyCode>RM</RequestedCurrencyCode>

<CurrencyCode>RM</CurrencyCode>

<StdDiscPercent>30</StdDiscPercent>

<PromoDiscValue>7.44</PromoDiscValue>

<ShipModeDescription>Air</ShipModeDescription>

<LineItemStatusCode>R</LineItemStatusCode>

<LineItemReason>

<LineItemReasonCode>E9850A</LineItemReasonCode>

<LineItemReasonDescription>Error Price is different from that in HP</LineItemReasonDescription>

</LineItemReason>

</POConfirmationLineItems>

</ServiceContent>

</Document>

</B2BGatewayDoc>

Outfile we have to get:

UNA:+.? '

UNBUNOC:3SENDERRECEIVER100625:1908+1'

UNH1ORDRSP:D:97A:UN'

BGM231SP30-60659-S++RE'

DTM+242:20100525T120000.000Z:304'

FTXSIN++RameshSP10RameshSP10RameshSP10RameshSP10RameshSP10RameshSP10RameshSP70:RameshSP10RameshSP10RameshS100'

FTXACD++RSRJCT'

FTXAAO++Info The order has been rejected by HP-RSAP'

FTXACD++E9850A'

FTXAAO++Error Price is different from that in HP'

FTXDIN++RameshSP10RameshSP10RameshSP10RameshSP10RameshSP10RameshSP10RameshSP70:RameshSP10RameshSP90'

FTXACB++455'

RFF+IT:HAERFZ'

RFF+ACT:90198816'

NADST544759087:160:16'

NADBYINS:160:92'

CTAAT:YANG MINGJIN(IRENE'

COM+IRENE.YANGINGRAMMICRO-ASIA.COM:EM'

COM+021-24016684:FX'

COM+021-24016753:TE'

NADSEINS:160:92'

CTAAT:HP CO OM'

COM+GOPALKRISHNANVHP.COM:EM'

COM+65-67271815:TE'

SCC9BK'

LIN17'

PIA5001:PL'

PIA551645AA:VP'

IMDF+:::NLA - REORDER 51645BA (40)'

QTY+21:40'

QTY+113:40'

DTM+137:20100611030920:304'

DTM+2:20100630:102'

FTXTRA++Air'

FTXACD++E9850A:Error Price is different from that in HP'

PRI+INF:167.44::QTE'

CUX+3:RM:9'

PRI+INF:160::NTP'

CUX+3:RM:14'

PRI+INF:30::DPR'

PRI+INF:7.44::PRP'

RFF+ACT:90198816'

RFF+VN:999999999999'

UNS+S'

UNT411'

UNZ11'

Check it....

Thanks,

Kishore

shweta_walaskar2
Contributor
0 Kudos

Hello Kishore,

Thanks for sending me the files.

But my question still remains.From where do you get FTX Qualifiers like ACD,ACB,AAO and DIN?

These are not in the input file.

Can you please let me know?

Thanks.

Regards,

shweta

Former Member
0 Kudos

Hello Shweta,

I was working from Xml to EDIFACT Mapping.In the given mapping specification document he was specified to Hardcode "ACD" to FTX first element and If POConfirmationHeader.OrderReasonCode Is Not Null then map OrderReasonCode to FTX(4440).If Hardcode "AAO" to FTX first element and If POConfirmationHeader.OrderReasonDescription Is Not Null then then map OrderReasonDescription to FTX(4440).

Is it clear now.....

Thanks,

Kishore

Former Member
0 Kudos

Hi Kishore,

Dude you are doing a few things incorrectly.

As I understand your requirement is some kind of file as input and then you are sending EDIFACT message of a certain type to the partner and you are using Seeburger adapter along with BIC for it?

If above is the case, first thing first YOU DO NOT do the EDIFACT-XML to EDIFACT conversion that is done at the adapter level and some kind of standard mapping should already be there if not it can easily be generated using Seeburger Mapping designer, so that is first thing wrong you are doing as reading your question and looking at what you are trying to do, you are actually mixing up 'message mapping' with 'BIC mapping' - ideally one would like to keep the two separate.

All you have to do is Map your file-XML to EDIFACT-XML in the PI message mapping and you can use Graphical mapping easily for this.

If two points above are making sense let me know and I will try to explain further.

regards

Former Member
0 Kudos

Hi,

The two points u have specifeid are making sense.Can u expailn it further....

Thanks,

Kishore

Former Member
0 Kudos

HI

To me it seems like your required output is:

EDIFACT - Order Confirmation - D97A - UN

And Input File I am not too sure - but doesn't matter though.

So do the following steps:

1) If you have seeburger BIC there should be a folder in Seeburger's material called catalog. From that folder find out the XSD verison of the above EDIFACT version and Import it into PI

2) Import the XSD format of your input file as external definition

3) Do the message mapping of your external input file to this edifact xsd you imported - so basically mapping XML- Input to EDIFACT-XML

4) Then using the Seeburger Mapping Designer create the XML -to -Edifact conversion. For this you should be able to find enough material in seeburger material which comes with it.

5) Deploy the above on the server and call it in your Receiver channel in the module sequence/parameters

and thats it.

regards