Altova Mailing List Archives>Archive Index >microsoft.public.xsl Archive Home >Recent entries [Thread Prev] >Thread Next - Re: Text File Conversions Text File ConversionsTo: NULL Date: 12/7/2004 3:41:00 PM Guys, We have an EDI application which takes in flat files. There is now a need to accept a new format, and we wanted to involve XML, but my knowledge of XML is limited to how to spell it. From the net, I've found that flat files can be converted to XML relatively easily, but examples only show rows that are identical in structure. So my question is, can we do an XSL translation on something like: cust@b...|comp@b...|08/12/2004|ORDERS|28682351|V| HFCH DAC 2858591 0812200408122004J DPH1705W 4EA 2283Product 1 DQLG66K/4GPLWEWE 20EA 186Product 2 ...where we can have any number of _H_eader and _D_etail lines. You might also ask why we don't just receive XML itself - well, it's deemed "too expensive". Simon. P.S. The preferred option is shown below, with one field per line, with qualifiers for the fields and multiple values included in each field, but is very verbose. Could we "transform" this? Again, there are likely to be multiple header and detail lines. UNB+UNOA:3+cust:ZZ+supp:ZZ+0416022:098+0305' UNH+0001+ORDERS:D:96A:UN:EAN008' BGM+220+792775454231+9' DTM+2:20041202:102' DTM+137:20041201:102' FTX+PUR+++INVOICE WITH GOODS-NO BACKORDERS ALLOWED' NAD+ST+7127::92+Customer:Address Line 1:Suburb State Zipcode::' CTA+PD+:GOODS INWARDS - COST EXCL GST' COM+02 9571 9889:FX' COM+02 9571 9311:TE' NAD+SU+BB701::92+Company:Address Line 1:Suburb State Zipcode::' LIN+1++9224001165109:EN' PIA+1+0000000:IN' IMD+++:::Product 1' QTY+21:2.000:EA' PRI+AAA:15.000' TAX+7+GST+++:::5.00' UNS+S' MOA+128:3150.000' CNT+2:1' UNT+20+0001' UNZ+1+0001' | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
