Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
HI ALL,
I want to know that how to parse XML in qlikview.
Description of problemL:
Having table which contains two column A and B,A is varchar and B is clob.
B column has clob data in XML format,
I want to seperate the XML
the XMl format is :
<inv1:structureFormats>
<cus:sfType>ADDRESS</cus:sfType>
<cus:name>ADDR_FOR_INDIA</cus:name>
<cus:structureFormatComponents>
<cus:id>0</cus:id>
<cus:name>Address Line1</cus:name>
<cus:componentType>N</cus:componentType>
<cus:value>IT 3, Ground Floor, Zone 1&2, Incubation, BlueRidge, New Cognizant, Rajiv Gandhi Infotech Park</cus:value>
</cus:structureFormatComponents>
<cus:structureFormatComponents>
<cus:id>0</cus:id>
<cus:name>Address Line2</cus:name>
<cus:componentType>N</cus:componentType>
<cus:value>Phase 1, Hinjewadi</cus:value>
</cus:structureFormatComponents>
<cus:structureFormatComponents>
<cus:id>0</cus:id>
<cus:name>Address Line3</cus:name>
<cus:componentType>N</cus:componentType>
<cus:value/>
</cus:structureFormatComponents>
<cus:structureFormatComponents>
<cus:id>0</cus:id>
<cus:name>Landmark</cus:name>
<cus:componentType>N</cus:componentType>
<cus:value/>
</cus:structureFormatComponents>
<cus:structureFormatComponents>
<cus:id>0</cus:id>
<cus:name>Country</cus:name>
<cus:componentType>G</cus:componentType>
<cus:value>India</cus:value>
</cus:structureFormatComponents>
<cus:structureFormatComponents>
<cus:id>0</cus:id>
<cus:name>State</cus:name>
<cus:componentType>G</cus:componentType>
<cus:value>Maharashtra</cus:value>
</cus:structureFormatComponents>
<cus:structureFormatComponents>
<cus:id>0</cus:id>
<cus:name>City</cus:name>
<cus:componentType>G</cus:componentType>
<cus:value>Mumbai</cus:value>
</cus:structureFormatComponents>
<inv1:structureFormats>
This is an example for the column name A and suppose value is 1 and same XML is for the column name A value is 2.
How could i get the values in XML for particular column A and its value?
qlikview read in a native way xml files as a supported datasource
just in the script choose your xml file and that;s it.
make sure the xml is well formes, i noticxed that the sample you put is not.
the <inv1:structureFormats> is not closing
hector
if this si not the case check this