Current Page:
NeXtMidas Training
![]() ![]() ![]() |
|
nM> res t:tbl fleet.xml nM> res/all tbl T: TBL = Table of 3 entries T: TAB = Table of 3 entries T: CAR = Table of 3 entries 1S: DOORS = 4 1S: CYLINDERS = 4 10S: CDATA = 4 Door Car T: TRUCK = Table of 3 entries 1S: DOORS = 2 1S: CYLINDERS = 8 12S: CDATA = 2 Door Truck T: FLEET = Table of 3 entries 17S: CDATA = X="1" Y="2" Z="3" 40S: CAR_1 = NAME="CHEVETTE" HP="50" COLOR="BABYBLUE" 36S: CAR_2 = NAME="CORVETTE" HP="350" COLOR="RED"or by using the CONVERT command:
nM> convert/delim="__"/comp=ON fleet.xml XML2TAB tbl nM> res/all tbl T: TBL = Table of 3 entries T: CAR = Table of 3 entries 1S: DOORS = 4 1S: CYLINDERS = 4 10S: CDATA = 4 Door Car T: TRUCK = Table of 3 entries 1S: DOORS = 2 1S: CYLINDERS = 8 12S: CDATA = 2 Door Truck T: FLEET = Table of 3 entries 17S: CDATA = X="1" Y="2" Z="3" 40S: CAR__1 = NAME="CHEVETTE" HP="50" COLOR="BABYBLUE" 36S: CAR__2 = NAME="CORVETTE" HP="350" COLOR="RED" CONVERT command, one can control the delimiter used for
duplicate tags as well as the character data compression for tags with no params
(such as the CAR tags in this XML) With character data compression off the resultant XML looks like: nM> convert/delim="__"/comp=OFF fleet.xml XML2TAB tbl nM> res/all tbl T: TBL = Table of 3 entries T: CAR = Table of 3 entries 1S: DOORS = 4 1S: CYLINDERS = 4 10S: CDATA = 4 Door Car T: TRUCK = Table of 3 entries 1S: DOORS = 2 1S: CYLINDERS = 8 12S: CDATA = 2 Door Truck T: FLEET = Table of 3 entries 17S: CDATA = X="1" Y="2" Z="3" T: CAR__1 = Table of 1 entries 40S: CDATA = NAME="CHEVETTE" HP="50" COLOR="BABYBLUE" T: CAR__2 = Table of 1 entries 36S: CDATA = NAME="CORVETTE" HP="350" COLOR="RED" |
|