Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

XML Load keys do not match

Hi everyone!

I'm trying to load and xml File via a GET Request, and the Keys QV generates do not match. This is a sample of the XML File:

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

<TRANSACTIONS>

    <TRANSACTION>

        <PK_AUFTRAG_ID>26615728</PK_AUFTRAG_ID>

        <PK_SUBAUFTRAG_ID></PK_SUBAUFTRAG_ID>

        <POSITIONS>

            <POSITION>

                <BUCH_TICKETID>3841042886</BUCH_TICKETID>

            </POSITION>

        </POSITIONS>

        <PAYMENTS>

            <PAYMENT>

                <BUCH_ZAHLUNG_ID>17802472</BUCH_ZAHLUNG_ID>

            </PAYMENT>

        </PAYMENTS>

    </TRANSACTION>

    <TRANSACTION>

        <PK_AUFTRAG_ID>26615704</PK_AUFTRAG_ID>

        <PK_SUBAUFTRAG_ID></PK_SUBAUFTRAG_ID>

        <POSITIONS>

            <POSITION>

                <BUCH_TICKETID>3841042887</BUCH_TICKETID>

            </POSITION>

            <POSITION>

                <BUCH_TICKETID>3841042888</BUCH_TICKETID>

            </POSITION>

        </POSITIONS>

        <PAYMENTS>

            <PAYMENT>

                <BUCH_ZAHLUNG_ID>17802463</BUCH_ZAHLUNG_ID>

            </PAYMENT>

        </PAYMENTS>

    </TRANSACTION>

</TRANSACTIONS>

And this is the QV-Code generated:

POSITION:

LOAD

    BUCH_TICKETID,

    %Key_TRANSACTION_195A685AA8F793EA    // Key to parent table: TRANSACTIONS/TRANSACTION

FROM [URL] (XmlSimple, Table is [TRANSACTIONS/TRANSACTION/POSITIONS/POSITION]);

PAYMENT:

LOAD BUCH_ZAHLUNG_ID,

    %Key_TRANSACTION_195A685AA8F793EA    // Key to parent table: TRANSACTIONS/TRANSACTION

FROM [URL] (XmlSimple, Table is [TRANSACTIONS/TRANSACTION/PAYMENTS/PAYMENT]);

TRANSACTION:

LOAD PK_AUFTRAG_ID,

    PK_SUBAUFTRAG_ID,

    %Key_TRANSACTION_195A685AA8F793EA    // Key for this table: TRANSACTIONS/TRANSACTION

FROM [URL] (XmlSimple, Table is [TRANSACTIONS/TRANSACTION]);

The problem is now, that for the second transaction, the key in the table payment and position do not match to the key generated in the table transaction.

Has anyone an idea, why this is happening?

UPDATE: so far, I could figure out, that it has something to do with the Table Payment (there can be multiple payment tags in <payments>). It seams QV has problems there.

Thanks & best regards,

Benedikt

0 Replies