Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
Is it possible to append data to an existing table using a select?
Let's say that I have in a table A data from yesterday and I want to do a select for updating the table A with new data from today without loosing the data from yesterday. I noticed that when selecting data from today it replaces the whole table.
Thank you in advanced for your help.
Well in this case I recommend , you check few things here
1. In case you are concatenating the data, it means you must have had the old data in the qvd file and it must be existent
2. Check if the path specified for the qvd is correct, you can check this by trying to load from the qvd on another tab and see the path
3. In case you are using QV 12 , few users are seen to have reported this issue , and have said it is solved either when close and reopen the sample and try this action, and also by not using relative path. Please try the above and check if it helps
Thank you for your answer but it gave me problems in the script :
This is my script :
[PT_TABLE_A]:
LOAD * from PT_TABLE_A;
Could you post the error encountered.
I think the problem if you see in the error is that it does not get the old information (the one that I have already in Qlik Sense with a table_A) . If I execute separetly this one :
LOAD FIELD1,
FIELD2,
FIELD3;
SELECT "FIELD1",
"FIELD2",
"FIELD3"
FROM "DATABASE"."TABLE_A" WHERE FIELD3 between TO_DATE('2017-01-01 14:22:00','YYYY-MM-DD HH24:MI:SS')
and TO_DATE('2017-01-01 14:23:00','YYYY-MM-DD HH24:MI:SS');
If I change the date (Field3) all the time , it does not give me anytype of problem . Collect the rows from the database and delete the previus ones. The problem is keeping the old ones and take the new ones. It is like I can not add it new information to the same table witout deleting the old one with the script.
I tried the concatenate like you told me but it gives a error in the first load (the one that take all the old table).
Thank you for the help.
Hi,
The Solution to your problem is using incremental load please go through the link https://www.analyticsvidhya.com/blog/2014/09/qlikview-incremental-load/
Also attached , is the pdf with a slight complex script but can be caught up with once you get handy with the link shared
Thank you so much for the answer!!! yes !! I saw just now in the tutorial that I think that it is the same information that you have given to me. It looks complex but it is worth a try !! I will do the test.
Thank you.
So I have created like in the example with incrementals this script :
Connected