Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Dynamic Delete

Hello Everyone,

I have implemented dynamic update to insert a record within a table or field. But I want to delete not all data but data which is last inserted into the table.is this possible by Dynamic Update ?

to delete the field value I used following delete command


DELETE FROM TestTable WHERE -1


where TestTable is the name of the Table.

12 Replies
Not applicable
Author

Its 11.20 SR5

its_anandrjs
Champion III
Champion III

Correct this is from load script in the front end from the (UI) you can achieve this by creating the flag field in the loasd script means for the last rows and in the UI select without the last records

Ex:-

Load * Inline

[

City,Sales,Flag

A, 343454,0

B, 15482,0

C, 125659,0

D, 15823,0

E, 12563,1

];

And as you say DELETE is work on the script then try like


LET vLast = Peek('City' ,-1, 'Table1');


DELETE FROM TestTable WHERE FieldName = '$(vLast)';

And please read this post

Direct Discovery - can QlikView delete row in database?

SunilChauhan
Champion II
Champion II

see the attached

hope this helps

Sunil Chauhan