Qlik Community

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
QLIKWORLD LIVE! MAY 16 - 19TH, EARLY BIRD DISCOUNTS! REGISTER TODAY
cancel
Showing results for 
Search instead for 
Did you mean: 
amien
Specialist
Specialist

use API to push data?

With Qlik Sense, if i have no data model in an app, but has visualisations in it; is it possible to:

* use the API to push a table in the app?

* delete records from the table in the app?

I'm not looking for a hypercube, but really looking for a solution to push a datamodel into the app.

Thanks in advanved

1 Solution

Accepted Solutions
rwunderlich

There is no current API to push data into the model.

You can insert script and initiate reload via API.

-Rob

View solution in original post

10 Replies
thiago_justen

Amien,

Try this out:

1- In the main tab (script editor) put this at the top of code (before variables):

     Binary YOURQVFFILENAME.qvf;

   

2 - Create a folder connection where you want to save app's qvd files;

3 - Run this code:

FOR i = 0 TO NoOfTables() - 1

LET vTableName = trim(TableName(i));

    STORE $(vTableName) INTO [lib://FOLDERCONNECTION/$(vTableName).qvd] (qvd);

NEXT i;

FOR i = 0 TO NoOfTables() - 1

LET vTableName = trim(TableName(i));

drop table $(vTableName);

NEXT i;

Then, your data model is there!!

Thiago Justen Teixeira Gonçalves
WhatsApp: 24 98152-1675
Skype: justen.thiago
amien
Specialist
Specialist
Author

Hi Thiago,

Thanks for your reply.

But i don't want to use any database source, QVD files, QVF or excel files.

I want to use an API call (which contains json with data) and put this into an empty app to create a table.

thiago_justen

Well, sorry my mistake...

I'll try to learn something useful about that.

.

Thiago Justen Teixeira Gonçalves
WhatsApp: 24 98152-1675
Skype: justen.thiago
rwunderlich

There is no current API to push data into the model.

You can insert script and initiate reload via API.

-Rob

amien
Specialist
Specialist
Author

That's really too bad RW ..

amien
Specialist
Specialist
Author

@rwunderlich

Really to bad you also can use partial reload .. but only add .. not update (removing an deleted order for example.)

ErikWetterberg

Not sure if this is what you are after, but there is a library called Halyard js:

https://branch-blog.qlik.com/halyard-js-553b41df3b24

Haven't tried it, and I don't know if it solves your problem, but check it out!

Hope this helps

Erik Wetterberg

amien
Specialist
Specialist
Author

Thanks for this Erik, will sure look into this; but from what i read; This js library can add records, but not update records (or delete and add).

rwunderlich

Potentially you could use a partial reload with an inner join to delete rows. Haven't tried it myself.

-Rob