View Full Version : X12309 EDI schema
Prafulla
12-12-2002, 11:19
Hi All,
I am converting a xml file into X12.309 EDI. I am able to genertae a Record from XML. I want to genertae a EDI String using the record. How to do it?
I was trying to add envelop using "addICEnvelopEDIFACT" where syntaxId =UNOA" and applicationRefrence is Record name [ which i have created using EDI schmea of X12.309]
It's giving me an error as "Invalid Document".
I want to add enevelop [I am not sure wethere this is mandtory to do it]. Is it necessary to do this? Or I can do only "converToString" and use that string as EDI string.
Prafulla
michelle_123
12-12-2002, 11:54
Prafulla,
Since your document is an X12 document, you need to use the X12 envelope services. Before you do the IC envelope, you need to add a group envelope.
Use the service wm.b2b.edi.util:addGroupEnvelope for the group and wm.b2b.edi.util:addICEnvelope to add the interchange envelope.
Hope this helps.
Michelle
The overview of steps:
1. Read XML
2. Convert XML to record (record is structured like the XML doc) -- sounds like you've already gotten this far
3. Convert this source record to a 309 record (you define the 309 record by importing the schema downloaded from wM)
4. Convert the 309 record to a string using convertToString
5. Wrap the 309 transaction set with the group envelope and then with the interchange envelope using the appropriate wM services.
As Michelle points out, if you want anyone to accept your 309 doc you'll need put envelopes on it.
HTH
Prafulla
12-13-2002, 02:34
Thanks for ur prompt reply.
I tried with wm.b2b.edi.util:addGroupEnvelope for the group
it's giving me an error
"required input signature is not specified (see "errorMessage" for detail)"
are there any values to be specified?
I'll repeat the steps I am following afetr creating record.
1. Setting up Delimiters [ Field as + subfield as : and Record ' ]
2. Calling service ConvertToString
Mapping created record to Values, nsRecord as a schema refrence [for exa : USA_X12_309:Record_USA_X12_309]
and mapping the delimiters.
3.Converting string to StringList
4. calling service wm.b2b.edi.util:addGroupEnvelope
mapping delimiters to delimiters
and stringlist generated above to documents.
Hardcoding "sender" and "reciver"
here i'm getting the above error.
5. Calling wm.b2b.edi.util:addGroupEnvelope .
Pls help me.
prafulla
12-13-2002, 04:23
Need more help
prafulla,
Read the following 2 links they may provide some additional info.http://www.wmusers.com/wmusers/messages/117/966.shtml?
http://www.wmusers.com/wmusers/messages/117/884.shtml?
Also I don't see you mention validate. Are you validating the document before you attempt to envelope it.
Also when you validate a document it requires that the ST02, SE01 and SE02 be present. You have to fill them in with dummy numbers in the correct lengths to pass validation. After validation you must remove them so that addGroupenvelope and addICEnvelope can insert the correct control numbers.
Have you loaded the correct standards?
Read the wm EDI Module: Trading Networks Component User's Guide for info on how to do this.
HTH
prafulla
12-14-2002, 08:17
Hi
Can I have an email id of u? So i can mail u and give u more details.
Any way I'll repeat my prob .
I am sending an OUTBOUND edi . [X12.309]
and facing prob while doing record to edi conversion.
I'll repeat the steps I am following after creating a record.
1. Setting up Delimiters [ Field as + subfield as : and Record ' ]
2. Calling service ConvertToString
Mapping created record to Values, nsRecord as a schema refrence [for exa : USA_X12_309:Record_USA_X12_309]
and mapping the delimiters.
3.Converting string to StringList
4. calling service wm.b2b.edi.util:addGroupEnvelope
mapping delimiters to delimiters
and stringlist generated above to documents.
Hardcoding "sender" and "reciver" and
IDcode =309, grpCtlNumber=309,agencyCode=T,verRelCode=4010
5. Calling wm.b2b.edi.util:addICEnvelope .
Here I am getting an error
"com.wm.lang.flow.FlowException: required input parameter is not specified (see "errorMessage" for detail)"
In this step Iam hardcoding
sender,receiver,ackRequested=0,testIndicator=P,addGroup=false.
do I suppse to do anything else?
pls help.
Pls help me.
After addGroupEnvelope, you need to convert the returned string to a string list. Pass this string list to addICEnvelope.
prafulla,
How did you make out?
Is your problem resolved?
Chris