# Database to edi

**URL:** <https://techcommunity.softwareag.com/t/database-to-edi/107558>\
**Category:** Forum\
**Tags:** EDI\
**Created:** [April 12, 2004, 8:30pm UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558 "2004-04-12T20:30:11Z")\
**Posts on this page:** 15\
**Page:** 1

<div class="post-metadata">

**Author:** ![Guest](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/guest/32/75_2.png) [@Guest](https://techcommunity.softwareag.com/u/Guest)\
**Post date:** [April 12, 2004, 8:30pm UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/1 "2004-04-12T20:30:11Z")

</div>

Hello all,  
Im new to webMethods and here im with a problem which is draining me.Im successful in inserting the required data from edi(850) into database(SQL SERVER).Now i want to know whether i can gat an edi document from the database values i have inserted.Please let me know this.Thanks in advance…

Nivas

---

<div class="post-metadata">

**Author:** ![gupta\_r.17495](https://avatars.discourse-cdn.com/v4/letter/g/9fc348/32.png) [@gupta\_r.17495](https://techcommunity.softwareag.com/u/gupta_r.17495)\
**Post date:** [April 12, 2004, 8:43pm UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/2 "2004-04-12T20:43:09Z")

</div>

Nivas,

EDI document cannot be directly created from database,first you need to retrieve/extract the database values and then do mapping of individual values to appropriate EDI segments to prepare the final edi docume.

Regards,

---

<div class="post-metadata">

**Author:** ![Guest](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/guest/32/75_2.png) [@Guest](https://techcommunity.softwareag.com/u/Guest)\
**Post date:** [April 12, 2004, 11:20pm UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/3 "2004-04-12T23:20:19Z")

</div>

RMG,  
thanks for ur reply.but can u please be more specific.

---

<div class="post-metadata">

**Author:** ![Guest](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/guest/32/75_2.png) [@Guest](https://techcommunity.softwareag.com/u/Guest)\
**Post date:** [April 12, 2004, 11:20pm UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/4 "2004-04-12T23:20:27Z")

</div>

RMG,  
thanks for ur reply.but can u please be more specific.

---

<div class="post-metadata">

**Author:** ![Guest](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/guest/32/75_2.png) [@Guest](https://techcommunity.softwareag.com/u/Guest)\
**Post date:** [April 12, 2004, 11:21pm UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/5 "2004-04-12T23:21:52Z")

</div>

RMG,  
thanks for ur reply.but can u please be more specific.

Regards

---

<div class="post-metadata">

**Author:** ![gupta\_r.17495](https://avatars.discourse-cdn.com/v4/letter/g/9fc348/32.png) [@gupta\_r.17495](https://techcommunity.softwareag.com/u/gupta_r.17495)\
**Post date:** [April 12, 2004, 11:40pm UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/6 "2004-04-12T23:40:28Z")

</div>

Nivas,

You need to query the source data from database which gives the results as a recordlist set in webMethods.Then map these values to (EDI50)record structure (segment mapping)what ever fields you specification require and finally using WmEDI package there are some built-in services available like(convertToString,addICEnvelope,addGroupEnvelope) which helps to create the EDI document.

There are lot of discussions done in this forum,about creating the EDI document,basic services to use.Please use the search functionality.

BTW which version of webMethods/EDI you are using?

Regards,

---

<div class="post-metadata">

**Author:** ![vikram4](https://avatars.discourse-cdn.com/v4/letter/v/73ab20/32.png) [@vikram4](https://techcommunity.softwareag.com/u/vikram4)\
**Post date:** [April 13, 2004, 3:18am UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/7 "2004-04-13T03:18:52Z")

</div>

Nivas,  
Checkout the webMethods provided wmEDISample packags. they have shown how to convert XMl(DB values) into EDI and EDI859 and vice versa.  
It will be really help.  
If this does not work let me know I will give you mapping services.

---

<div class="post-metadata">

**Author:** ![Guest](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/guest/32/75_2.png) [@Guest](https://techcommunity.softwareag.com/u/Guest)\
**Post date:** [April 13, 2004, 8:52pm UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/8 "2004-04-13T20:52:12Z")

</div>

vikram,  
examples in wmEDISample package r lil confusing.can u help me in this.Im trying to convert the values from database to edi.i first extracted the values from the database and then used the service convertToString.Please tell me what to do next.

Thanks,

---

<div class="post-metadata">

**Author:** ![Chris\_L](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@Chris\_L](https://techcommunity.softwareag.com/u/Chris_L)\
**Post date:** [April 14, 2004, 1:54am UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/9 "2004-04-14T01:54:42Z")

</div>

Nivas,

Is this inbound or outbound EDI to you? I’m assuming outbound application (database) to EDI but please confirm.  
What version of wm are you using?  
Exactly what have you done so far?  
Do you have an Idata object that represents your application file?  
Do you have an Idata object that represents your X12 EDI?  
Have you mapped the one to the other?  
When you used converToString what did you get.

What in wmEDISamples package didn’t you understand.  
The more detail the better.

And finally, Don’t cross post.  
Answer the questions and let’s see if we can help you.

---

<div class="post-metadata">

**Author:** ![Guest](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/guest/32/75_2.png) [@Guest](https://techcommunity.softwareag.com/u/Guest)\
**Post date:** [April 14, 2004, 2:23am UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/10 "2004-04-14T02:23:29Z")

</div>

Chris,  
This is outbound EDI im doing.Wm version is 6.0.1.i have a table containing the some data related to tax segment of 850 edi .now i want to convert the data in the database to edi.After extracting the data from database …i used convertToString,which gave a string pertaining to the schema i created.now i want to know how to map these values in the database to the edi record structure.

---

<div class="post-metadata">

**Author:** ![gupta\_r.17495](https://avatars.discourse-cdn.com/v4/letter/g/9fc348/32.png) [@gupta\_r.17495](https://techcommunity.softwareag.com/u/gupta_r.17495)\
**Post date:** [April 14, 2004, 2:44am UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/11 "2004-04-14T02:44:30Z")

</div>

Nivas,

Once you have extracted the data from database it will give the results (IDATA object).Nextstep will is loop thru results and map the tax values to TAX segment of 850 recordstructure(ST/TAX), like this map rest of the required segments and form an ST segment that contains (eg:BEG,N1,LIN,TAX segments etc…)  
.  
Finally invoke the convertToString and here map the ST segment which i have mentioned above, set the edi 850 schemaname,delimiters following with addICEnvelope(ISA/IEA),addGroupEnvelope(GS/GE) services to generate (Envelope segments) to prepare the valid EDI 850 document (ISA/GS/ST/SE/GE/IEA.

Regarding mapping of addICEnvelope,addGroupEnvelope mapping,refer the WmEDISamples package which will help you with necessary information.

HTH,

---

<div class="post-metadata">

**Author:** ![Guest](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/guest/32/75_2.png) [@Guest](https://techcommunity.softwareag.com/u/Guest)\
**Post date:** [April 14, 2004, 2:48am UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/12 "2004-04-14T02:48:45Z")

</div>

RMG,  
Thank u very much for ur info.I’ll go thru the steps u mentioned and get back ,for further clarifications if any…

Thanks,

---

<div class="post-metadata">

**Author:** ![Guest](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/guest/32/75_2.png) [@Guest](https://techcommunity.softwareag.com/u/Guest)\
**Post date:** [July 5, 2004, 11:41am UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/13 "2004-07-05T11:41:41Z")

</div>

Hello Professionals,  
I am trying to create an XML file by the data which is results from an adapter service. I have multiple records in my hand. Can any one help to generate an XML file for the multiple records.

Thanks

Nani

---

<div class="post-metadata">

**Author:** ![Chris\_L](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@Chris\_L](https://techcommunity.softwareag.com/u/Chris_L)\
**Post date:** [July 5, 2004, 6:09pm UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/14 "2004-07-05T18:09:18Z")

</div>

Nani,

I see you got your answer in another post. Please do not cross post.

Thanks.

And please register.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 3:04pm UTC](https://techcommunity.softwareag.com/t/database-to-edi/107558/15 "2021-04-02T15:04:51Z")

</div>


