Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
twanqlik
Creator
Creator

QvRestConnector creates invalid keys

I'm using the QvRestConnector in Qlikview to extract data via an API call from Eloqua.

The QvRestConnector creates in the JSON SQL select script keys to link tables.

In my script, the created keys are invalid, they link objects that in Eloqua are not linked.

Example:

In Eloqua a test campaign has only 1 email, the email has ID 76

1.PNG

When i create an API Call to Eloqua and I extract only the details of this Campaign, it results in 1 Email ID, that is 76. There it works correct.

When i create an API call to Eloqua in order to extract all the Campaigs, suddenly this Campaign has 2 Email ID's, 76 and 235:

2.PNG

The 2 tables are linked with the __KEY_elements key, created in the JSON script:

3.PNG

RestConnectorMasterTable:

SQL SELECT

"type" AS "type_u4",

"id" AS "id_u3",

"createdAt" AS "createdAt_u0",

"name" AS "name_u1",

"__KEY_elements",

     (SELECT

     "emailId",

     "__KEY_elements_u0",

    "__FK_elements"

FROM "elements" PK "__KEY_elements_u0" FK "__FK_elements")

FROM JSON (wrap off) "elements" PK "__KEY_elements";

The __KEY_elements value from the table containing the emailID is 1 for EmailID 235 and 76.

The __KEY_elements value from the table containing the Campaign details is also 1.

I don't understand how Qlikview creates these keys, because the __KEY_elements key shouldn't be 1 for EmailID 235, because in Eloqua it's not linked.

To verify my analysis i created the same API call in Postman, and there EmailID 235 is not linked to this example Campaign.

Does this mean that Qlikview cannot be used for using an API connection with Eloqua?

4.PNG

1 Reply
twanqlik
Creator
Creator
Author

Gosh, i think i finally found the root cause, i selected 'Sequence ID'  as a Key generation strategy. With 'Current record'  it seems to work fine.