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: 
Anonymous
Not applicable

Job: update and delete on the same table that does not allow block update

Hi,

 

I read from a table(cust_table) where the field_1(say address field with 10000 rows) is null and wanted to delete records where field_1 & field_2 are null(say address field is null and course field is also null with 1000 rows) and process remaining 9000 rows and update the same table.

 

How can this be achieved?

 

Thanks 

Labels (2)
1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Hi,

 

    You can follow the below steps to accomplish the process.

 

a) Fetch the key table columns and field_2 from source table where field_1 is null.

b) Pass the value to a tMap and in the output expression section do a check where field_2 is null. This will pick all the records where both field_1 and field_2 are null. You can pass these records to deletion process. Use the key columns in the input flow as keys for deletion

c) Come back to the tMap and create another flow and this time mark the "Catch output reject" as true. This will pick all the records which did not satisfy the previous condition. This means the data will have field_2 as not null. This can be passed to the update flow and use the key columns to do the update process.

 

Hope I have answered your query to satisfaction. Could you please mark the topic as resolved if the details are fine? Kudos are also welcome 🙂

 

Warm Regards,

 

Nikhil Thampi

View solution in original post

1 Reply
Anonymous
Not applicable
Author

Hi,

 

    You can follow the below steps to accomplish the process.

 

a) Fetch the key table columns and field_2 from source table where field_1 is null.

b) Pass the value to a tMap and in the output expression section do a check where field_2 is null. This will pick all the records where both field_1 and field_2 are null. You can pass these records to deletion process. Use the key columns in the input flow as keys for deletion

c) Come back to the tMap and create another flow and this time mark the "Catch output reject" as true. This will pick all the records which did not satisfy the previous condition. This means the data will have field_2 as not null. This can be passed to the update flow and use the key columns to do the update process.

 

Hope I have answered your query to satisfaction. Could you please mark the topic as resolved if the details are fine? Kudos are also welcome 🙂

 

Warm Regards,

 

Nikhil Thampi