EDI knowledge

Dear All,

I am in learning stage of EDI documen. Few days before i have Started reading document related to EDI. I have few query to understand out that.

If we have sfs file then we can crete the schema directly by using b2b.edi:SEFParse
service. I have tried to create the schema by sfs files given in location
\IntegrationServer\packages\WmEDI\pub\SEFS\X12 but b2b.edi:SEFParse this asking url as
input so how we can create schema then.

how we can get this sfs files.this al sfs files are common for same EDI number like 850.

created the document type by EDI admin page by given as paramter :
standard : x12
version : 4010
Transaction set: 850
when i try to test document type in TN. its given error as “here was an error in trying to
get XML header information (DOCTYPE and DTD). The document (vg0001003in960ms0000000m) is
probably not valid XML.” How we can test the EDI document in TN then.

Regards
Reema

If you can elaborate more on your query,we can guide you in a better way.

What you mean “test document type in TN”?? How are you testing…is it thru a flow service (routeXML or tn:receive) that routes EDI X12 850 data to TN…

Did you created profiles,processing rules,EDI document types(you already created this) etc…using TNConsole

Please review these pdf’s EDI_Module_Users_Guide,EDI_Module_Built-In_Services_Reference,Trading_Networks_Users_Guide for more information it covers most part of EDI/TN setup/procedures.

HTH,
RMg

Dear All,

I have install the TD document type from EDI console and its showing 3 document in Trading network “X12 4010 850”,“x12 Envelope”,“x12 Group”.

In processing rule i have selected the sender and reciver and in document type i have selected all 3 types of document “X12 4010 850”,“x12 Envelope”,“x12 Group”.In Action tag i have seleted Execute a service and in that service i called only debug log.

I created the TPA in which i have mention
agreement id = EDITPA and as
in IS Document Type= wm.b2b.editn.TPA:EDITPA
control number =0
initialization service = wm.b2b.editn.Tpa:initService
in IS Document Type
splitOption = Interchange
FAGeneration/autoGenerateFA = off
FAGeneration/FALevel = default
FAGeneration/processDocument = All
FAGeneration/generateControlNumber = FromInbound.

I have submitted the EDI document by TN Admin page.

In Transaction Analysis i got X12Envelope. but when i saw the content in it its showing whole document which i have send for process.is this correct evenwhen splitOption = Interchange is mention.

I Service i used convertTovalue and EDIValues i saved to file. In file it converted from ST to SE label. is this correct for when splitOption = Interchange mention.

Please let me know my understanding is correct regariding the EDI processing.

I have few doubts which i need to understand

  1. In Pdf its mention as standard and non -standard processing of document.what it means and diffrence in both and how we can achive

  2. Mention about control number. for what is use of this control number and how we change this.

  3. Regading FA we can do it in 2 ways either by caling the service or setting the parameter in wm.b2b.editn.TPA:EDITPA parameter in TN document.If i have to call the service then how i can do it in processing rule for reciver i have already called one service for execution then how i can achive this. and suppose if i used auomatic FA genration then where i can see its output and how i can used this in executable service.

Thanks in Advance

Reema

Dear All,

Can you please help me to find me solution for understand the EDI process.Please respond the above point also.

I have process the EDI with three diffrent Split option Interchange,transaction and group, but i find only diffrence in transaction task some time we view envelope document,group document and transaction type.

but in process rule when executing the service i found that even using the 3 diffrent type of split conditon the outout which is comming is same EDI document which we send for processing to TN.

wheater i have done any mistake in some rules or some other reason is there.
I want to know what is use of using this split conditon operation and what we achive by doing so.wheater we get diffrent types of input file for executing the service when we use this ?.

Thanks in Advance
Reema

In the ProcessingRule under the Documenttype you dont need to select all 3 types…just select x12 Envelope.Also in the TPA when you select splitOption=Interchange level the TransactionAnalysis page it will show only x12 Envelope and hides the X12Group,X12 4010 850…this doesn’t hurt any thing.

When comes to Execute Service ie the receiving service you will have bizdoc(BizDocEnvelope) document in the pipeline and you will be able to extract the content from the bizdoc/content (bytes).

bytesToString
envelopeProcess (If required)
getEDIString (extracts ST level data)
converToValues (Parses the EDI Document) you map the output to 850DT
…

HTH,
RMg

In addition to processing at the interchange level in your service, another option to consider is to split to the transaction level in the TPA. In this way, your service won’t have to process the envelope and do any of the splitting yourself–you’d just process the transaction. TN will invoke your service for each transaction set in the interchange. Typically, you don’t need to do anything explicit with the X12 Envelope or X12 Group documents, so you don’t necessarily need rules to process them.

Hi Rmg,Reamon,

Thanks for your prompt reply.

I have tested the EDI docment by given the 3 different split option in TPA and also selecting the 3 different type of document type in processing rules.

Below i have mention condtion which i have tested the EDI document.

A. In processing rule Document Type = X12 Envelope
Split Option= interchange

Service executed where i used convertTovalue and that value i savedinpipleline.

B . In processing rule Document Type = X12 Group
Split Option = Group

In transaction Analyisis X12Envelope and X12Group is showing but error is comming as.
“An error occurred invoking the processing service EDITEST:Tested for this document. The original error was com.wm.app.b2b.server.ServiceException: [FFP.0018.0009] Input parameter ffData cannot be null. at pub.flatFileImpl.convertToValues(flatFileImpl.java:210) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java(Compiled Code)) at java.lang.reflect.Method.invoke(Method.java(Compiled Code))”

But when i select Document Type = X12 Envelope and X12 Group the Executable service run sucessfully.

c. In processing rule Document Type = X12 4010 850
Split Option = transaction

I am getting the same error as mention above but when i seleced all 3 document type in processing then Service execute successfully.

I have attached input and all 3 output which i am getting.

I found that there is no diffrence in all 3 output file.Even selecting the diffrent type of slipt option and document type result are comming same.

Can u please advice me for what purpose this all diffrent option we choose and what is the purpose of doing so becouse output is comming same for all 3 option.

For clarification i have attached input edi file and all 3 output file also.

Thanks in Advance
Reema
Input.zip (4.06 KB)
Output.zip (88.3 KB)

c. In processing rule Document Type = X12 4010 850
Split Option = transaction

The error above indicates wm.b2b.edi:convertToValues step is failing because ffData input is null…might be bizdoc extraction not working with the transaction split.

Are you seeing the document X12 4010 850 persisting and kicks off the right processing rule?? To check this click on the document and look in the ActivitLog tab.

Also step thru the flow and check the pipeline till the convertToValues step and debug it…Only this way you can determine the root cause…

You can use any of the options (no need all three though) but as Rob pointed out use the transaction or Interchange split either way it works and when you process Interchange level then the receiving service will get whole ISA,GS,ST to SE,GS,IEA segment content(assuming you are receving only 850 transactions in the ISA/GS incase of multiple or single) and which might use in the downstream esp incase you need to extract sender/receiver,document date/time information in your Internal mapping purposes.

HTH,
RMG

The structure of EDI documents is this:

Interchange envelope
…Group envelope
…Transaction set
…Transaction set
…(more)
…Group envelope
…Transaction set
…Transaction set
…(more)

Each interchange can contain 1 or more groups and each group can contain one or more transaction sets (each group holds a single type of transaction sets).

If your EDI document has just one transaction set and you split to the transaction set level, then the interchange, group and transaction documents will all be exactly the same. If the EDI doc had more than 1, then the resulting TN docs will differ.

For example, say your EDI doc has 2 purchase orders and an invoice and the TPA indicates to split to the transaction set level. The EDI doc and the X12 Envelope doc in TN would be:

Interchange envelope
…Group envelope (850)
…Transaction set (PO 1)
…Transaction set (PO 2)
…Group envelope (810)
…Transaction set (Inv 1)

There would be 2 X12 Group docs in TN, 1 for each group:

Interchange envelope
…Group envelope (850)
…Transaction set (PO 1)
…Transaction set (PO 2)

Interchange envelope
…Group envelope (810)
…Transaction set (Inv 1)

There would be 2 X12 850 docs in TN, and 1 X12 810 doc:

Interchange envelope
…Group envelope (850)
…Transaction set (PO 1)

Interchange envelope
…Group envelope (850)
…Transaction set (PO 2)

Interchange envelope
…Group envelope (810)
…Transaction set (Inv 1)

This is all explained in the EDI Module Concepts Guide in the “EDI Documents Inbound Processing” section.

When processing the bizdoc in your service, make sure you get the content from the bizdoc and pass it to wm.b2b.edi:convertToValues. See the EDI Module User’s Guide for example code.

Dear Reamon,

Thanks Reamon to explain the concept of EDI so nicely. Its really Helpful to understand more about EDI.

I tried to search EDI 850 document where there is different group envelope. So that i can test for all three split condition.

If u have sample file for this please send us to understand more about EDI.


There is control number in TPA. What is use of this control number and is that any things related to document control number. Can u please advice on this part?
How these control numbers help in processing of document?

FA we can generate automatically or we can call service. Since we can call only on service in Execute service then how we can achieve this FA execution then?

Thanks

Reema

TN will automatically generate an FA if the TPA is configured to do so an you’re splitting to the group or transaction level. You don’t need to do anything to generate the FA. However, you may need to create a rule to deliver the generated FA. The docs have info on this.

Try searching for tutorials or examples containing multiple group envelopes. Don’t search for say, 850, because you’ll get hits for just a single group. Remember that group envelopes wrap transaction sets of the same type (e.g. all 850s, or all 810s).

The control numbers can be used when enveloping EDI documents that you create to be sent out. Each envelope has a control number.

Interchange - typically sequential for exchanges between 2 partners. For example, Company A sends to Companies B and C. The control number sent to each will start at 1 and increment independently from then on. This allows the receiver to detect missing ISA envelopes–“Hey, I just got number 143 but never saw 142.”

Group - typically sequential for a given group type (e.g. PO, IN, etc.) and a given partner. These numbers increment independently by group and by recipient. This allows the receiver to detect missing groups of a given type–“Hey, I just got PO group 323 and IN group 144 but I didn’t see 322 nor 143 respectively.”

Transaction - this control number is usually sequential within a group, starting at 1. Tracking isn’t done at this level. This control number is normally just used for file integrity checks.

There is much material on the web about EDI and common practices. Between that and the wM docs you should be able to get more familiar with EDI.

Hope this helps.

1 Like

Dear Reamon,

For checking the FA automatically

I have mention the following criteria in TPA Agreement

splitOption = interchange

FAGeneration/autoGenerateFA = on
FAGeneration/FALevel = TransactionSet
FAGeneration/processDocument =ALL
FAGeneration/generateControlNumber = FromInboundDocument

Created another processing rules for FA with condition as

In criteria tab

Sender = receiver from the inbound document
Receiver = sender from the inbound document
TN document type = x12 Envelope

In Extended Criteria
EDI Outbound FA = true

And execited the service option in that I have called service in which input tag I have given bizdocEvevelope and savepipelinetoFile option.

I have saw the Transaction log its showing as .

System status is NEW; user status is UNMATCHED.

I tried the different option change in split option and FA generation even though the executable service is not executing and transaction log showing same status as UNMATCHED.

Reema