Author |
Message
|
madi |
Posted: Fri Jun 22, 2012 8:11 am Post subject: Extractng IDOCS as flat file using SAP Nodes |
|
|
 Chevalier
Joined: 17 Jan 2006 Posts: 475
|
Hello Gurus
Im pretty sure its possible, I want to extract the IDOCS from SAP in their flat file format, but cannot find any documentation about it. There are articles on how to post to SAP using flat file idocs but not how to pull them.
Can someone point me to any documentation about it?
Thanks
madi _________________ IBM Certified Solutions Developer - WMB 6.0 |
|
Back to top |
|
 |
mqjeff |
Posted: Fri Jun 22, 2012 8:14 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Well, I think you just make sure that SAP is emitting the IDOCs in flatfile format, which has nothing to do with configuring Broker.
Then you configure the SAP Input node to read the flatfile format. |
|
Back to top |
|
 |
madi |
Posted: Fri Jun 22, 2012 8:44 am Post subject: |
|
|
 Chevalier
Joined: 17 Jan 2006 Posts: 475
|
May be my question was wrong.
I want to use the SAP nodes to get data from the SAP system via an rfc connection. Do not want SAP to create file on the server or anything.
But by default WMB is creating the idocs in the xml format which is what i want to change to either fixed or delimited idoc.
does that make sense? _________________ IBM Certified Solutions Developer - WMB 6.0 |
|
Back to top |
|
 |
mqjeff |
Posted: Fri Jun 22, 2012 8:57 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
madi wrote: |
But by default WMB is creating the idocs in the xml format which is what i want to change to either fixed or delimited idoc.
does that make sense? |
No, not really.
Broker does not create any of the docs that it reads through the SAPInput node.
SAP creates those docs.
I admit I don't know the properties of the SAP Inbound connector well enough to know for sure that it can't instruct SAP to create a doc as an XML doc or a flatfile doc - but I don't think it does that. I believe it's a matter of what you configure SAP to provide over the endpoint that the SAP inbound connector attaches to.
Do you follow? What I'm saying is talk to your SAP administrator. |
|
Back to top |
|
 |
manoj.pacha |
Posted: Fri Jun 22, 2012 10:54 am Post subject: |
|
|
Newbie
Joined: 24 Apr 2011 Posts: 7
|
we are using a similar setup in our project. SAPInput node connected to MQ output queue and later in the next flow, read the BLOB data from <IDOCStreamData>
To my knowledge, i think that you cannot get the IDOC as a flat file |
|
Back to top |
|
 |
fjb_saper |
Posted: Fri Jun 22, 2012 12:48 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
You can get the IDOC as an IDOC structure... if you want it in the IDOC domain you'd have to create the SAPH header...
However the biggest difference between the IDOC structure and the flat file structure is that as a flat file you're allowed to drop any trailing spaces...
This is done at the segment level as each segment is 1063 bytes long (for the EDI_DD40 type) 1000 of which are for the segment data (sdata)....
So the IDOC is made of 1 EDI_DC40 segment (shorter than the EDI_DD40 IIRC) and n EDI_DD40 segments...
Each EDI_DD40 segment has a level and a segment identifier (first 63 bytes)... The SAP EDI system tells you what the order, level and allowed repetitions for each segment in the IDOC are...
The segment identifier determines the format to apply to the sdata part of the segment...
Remember in the file any trailing spaces are dropped from the segment...
If you are planning to use the broker to receive the SAP IDOC's and create the file... don't!!! Let the SAP EDI system create the file (way faster and more efficient).
Have fun  _________________ MQ & Broker admin |
|
Back to top |
|
 |
mqjeff |
Posted: Fri Jun 22, 2012 4:30 pm Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
fjb_saper wrote: |
If you are planning to use the broker to receive the SAP IDOC's and create the file... don't!!! Let the SAP EDI system create the file (way faster and more efficient). |
That's all well and good, but there's no reason to use a file in the first place for any sort of internal transfer of data...
 |
|
Back to top |
|
 |
fjb_saper |
Posted: Fri Jun 22, 2012 8:49 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
IIRC there are 2 ways to set up the adapter.
- As a generic adapter and the BLOB payload will have the IDOC format
- As a specific adapter for IDOC type x. This will render the IDOC in xml format...
Have fun  _________________ MQ & Broker admin |
|
Back to top |
|
 |
madi |
Posted: Sat Jun 23, 2012 8:29 am Post subject: |
|
|
 Chevalier
Joined: 17 Jan 2006 Posts: 475
|
fjb_saper wrote: |
IIRC there are 2 ways to set up the adapter.
- As a generic adapter and the BLOB payload will have the IDOC format
- As a specific adapter for IDOC type x. This will render the IDOC in xml format...
Have fun  |
thats exactly what i needed, want to be able to use the generic idoc flow and just get the idocs in the IDOC format.
If you guys are interested, this is requirement
EDI already has maps from the IDOCS to the EDI formats for the customers.
We (EI) want to get the IDOCS from SAP and pass them through to the EDI system so they dont have to redo their maps. Eventually we want to map all the IDOCS to a canonical model and give that to the EDI system which will mean new maps but thats for the future.
Oh, and there are no files in this design, its just MQ and SAP nodes.
Thanks guys
madi _________________ IBM Certified Solutions Developer - WMB 6.0 |
|
Back to top |
|
 |
fjb_saper |
Posted: Sat Jun 23, 2012 8:53 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
You mean they're using something like Gentran to map the IDOC to ANSI X12 and you're going to feed that system?  _________________ MQ & Broker admin |
|
Back to top |
|
 |
madi |
Posted: Mon Jun 25, 2012 6:02 am Post subject: |
|
|
 Chevalier
Joined: 17 Jan 2006 Posts: 475
|
fjb_saper wrote: |
You mean they're using something like Gentran to map the IDOC to ANSI X12 and you're going to feed that system?  |
Yes, apparently recommended solution from IBM. _________________ IBM Certified Solutions Developer - WMB 6.0 |
|
Back to top |
|
 |
|