Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Not applicable

Loading xml-Files an prepare date for graphics

I am trying the first steps in Qlikview and I have absolutely no idea how to solve this task with the following two xml files.

Hopefully someone of you can help.

What I want to do is:

I want to create a numberline, where you can see how long each person worked in the different department.

I need two of them, to compare the different countries.

Header 1Header 2

<?xml version="1.0" encoding="utf-8"?>

<Root>

    <Header>

    <Country>Country A</Country>

    </Header>

    <Customers>

        <Customer CustomerID="ABC">

            <CompanyName>ABC Markt</CompanyName>

            <ContactName>Josef ABC</ContactName>

            <Department>Marketing ABC</Department>

            <Date>08/2008</Date>

            <Phone>(+49) 555-1212</Phone>

            <FullAddress><Address>Musterstrasse ABC.</Address>

            <City>Musterstadt</City>

            <State>Musterland</State>

            </FullAddress>

        </Customer>

    </Customers>

    <Customers>

        <Customer CustomerID="ABC">

            <CompanyName>ABC Markt</CompanyName>

            <ContactName>Josef ABC</ContactName>

            <Department>Marketing XYZ</Department>

            <Date>05/2013</Date>

            <Phone>(+49) 777-1212</Phone>

            <FullAddress><Address>Musterstrasse XYZ.</Address>

            <City>Musterstadt</City>

            <State>Musterland</State>

            </FullAddress>

        </Customer>

    </Customers>

    <Customers>

        <Customer CustomerID="XYZ">

            <CompanyName>ABC Markt</CompanyName>

            <ContactName>Franz XYZ</ContactName>

            <Department>Marketing ABC</Department>

            <Date>01/2011</Date>

            <Phone>(+49) 555-3434</Phone>

            <FullAddress><Address>Musterstrasse ABC.</Address>

            <City>Musterstadt</City>

            <State>Musterland</State>

            </FullAddress>

        </Customer>

    </Customers>

    <Customers>

        <Customer CustomerID="XYZ">

            <CompanyName>ABC Markt</CompanyName>

            <ContactName>Franz XYZ</ContactName>

            <Department>Marketing XYZ</Department>

            <Date>01/2012</Date>

            <Phone>(+49) 777-3434</Phone>

            <FullAddress><Address>Musterstrasse XYZ.</Address>

            <City>Musterstadt</City>

            <State>Musterland</State>

            </FullAddress>

        </Customer>

    </Customers>

</Root>

<?xml version="1.0" encoding="utf-8"?>

<Root>

    <Header>

    <Country>Country B</Country>

    </Header>

    <Customers>

        <Customer CustomerID="ABC">

            <CompanyName>ABC Market</CompanyName>

            <ContactName>John ABC</ContactName>

            <Department>Marketing ABC</Department>

            <Date>08/2010</Date>

            <Phone>(212) 555-1212</Phone>

            <FullAddress><Address>100 Park Avenue.</Address>

            <City>New York</City>

            <State>NY</State>

            </FullAddress>

        </Customer>

    </Customers>

    <Customers>

        <Customer CustomerID="ABC">

            <CompanyName>ABC Market</CompanyName>

            <ContactName>John ABC</ContactName>

            <Department>Marketing XYZ</Department>

            <Date>05/2012</Date>

            <Phone>(212) 777-1212</Phone>

            <FullAddress><Address>100 Park ABC.</Address>

            <City>New York</City>

            <State>NY</State>

            </FullAddress>

        </Customer>

    </Customers>

    <Customers>

        <Customer CustomerID="XYZ">

            <CompanyName>ABC Market</CompanyName>

            <ContactName>Mark XYZ</ContactName>

            <Department>Marketing ABC</Department>

            <Date>01/2009</Date>

            <Phone>(212) 555-3434</Phone>

            <FullAddress><Address>100 Park Avenue.</Address>

            <City>New York</City>

            <State>NY</State>

            </FullAddress>

        </Customer>

    </Customers>

    <Customers>

        <Customer CustomerID="XYZ">

            <CompanyName>ABC Market</CompanyName>

            <ContactName>Mark XYZ</ContactName>

            <Department>Marketing XYZ</Department>

            <Date>01/2010</Date>

            <Phone>(212) 777-3434</Phone>

            <FullAddress><Address>100 Park ABC.</Address>

            <City>New York</City>

            <State>NY</State>

            </FullAddress>

        </Customer>

    </Customers>

</Root>

1 Reply

Re: Loading xml-Files an prepare date for graphics

It's not quite clear what do you want to do? Are this different files or are this different fields within one table?

In general qlikview could handle xml-structures very well directly on file-level (you could use the table-wizard for this). If it's not on file-level or is the xml not well formed you will need some additionally steps. Here a few links to give ideas what could be done if the (recommended) table-wizard isn't enough:

Re: Reading non unique XML nodes

XML string parsing, in QV LOAD script

- Marcus

Community Browser