webMethods Flat file to XML document scenario
Normal 0 false false false EN-IN X-NONE X-NONE
Step by step transformation of a XML file from flat file using wM 6.1
1) Create a flat file in some directory
2) Create records in the flat file, each record having some fields, separate the fields in records by delimiters & separate the records by delimiters share it.
3) Select new â All choices
â Flat file dictionary
-Name the dictionary
-finish
-Flat file dictionary created
4) Select the dictionary
Record definition
New emp
New âfield definition Fields eno ename esal
Extractor type- n th field Position 0 1 2
4) Select new- All choices â Flat file schema
5) Choose â Flat field definition
Select âRecord delimiter as record separator
Select â Field delimiter as field separator.
(properties press set button)
((give the path of flat dictionary & press finish))
It shows record reference.
6) Then click on create document type button next next finish
It will create schema DT of document type
7) Create an XML document with same fields as flat file schema
Select Document as root
And Document list as schema name
And Strings as records
8) Add a flow service to get the file
Winpub.pub.file.getfile
Get file and load as bytes
Double click on file name-
Select the path of flat file
Paste it in the message box
9) Add a flow service to convert the values of the flat file (inside service)
Winflatfile . pub.flatfile.convert to values
body
bytes map to flatfile data
double click on flatfile schema
copy the schema name and paste it in the message box (inside pipeline out)
-select â document â reference
Ctl â v
Copy schema DT & paste as name of the Document reference
Map flat file values and schema DT Reference
10) Select a map(flow service)
Create new document ref. - copy XML document name & paste.
Pipeline In Pipeline Out
MAP (XM/XML)
fH schema DT XML Doc
record Root
Emp (schema)
R1 R1
R2 R2
R3 R3
Mapping of schema document values to XML document values.
11) Add a flow service to convert XML document to XML string
Winpub . pub . XML document to XML string
XML map document
12) Add a flow service
Win sample .sample. Io . test . write to file
XML data map file content
Then it will generate an XML file at a specified path
Similar Blogs:
webMethods step by step XML to Flat file
webMethods step by step flat to xml
webMethods step by step flat file to xml

Ingre heigh
it's useful , good collection
Paparao
it's useful , good collection