Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
iczkla
Contributor III
Contributor III

Checking for Removed/Deleted Records

Hello,

I have an app into which each month I am loading new Headcount file. Each employee is identified by unique ID and files are segregated by report period derived from title in format YYYY-MM.

I want to create a table in which each month I will be able to identify new and terminated employees.

So far I managed to create solution for identifying new employees by using below statement in the script:

if(previous([EMP ID])<>[EMP ID],'Yes','No') as "New Hire",

however I am struggling to create a statement which will allow me to identify terminations (ID's which were existing within previous period but are not existing in the new one). 

Any suggestions on how to achieve this will be much appreciated.

Labels (4)
3 Replies
mayuringale25
Partner - Creator
Partner - Creator

Hi @iczkla 

 

Can you share the data dump so it would be easy to understand 

Thanks and Regards
Mayur Ingale
OmarBenSalem

try to think about incremental load.

You store ur table in a qvd, then load the new one and compare the 2 (with left keep and flaging or where exists/not exists).

That way, you could do so much; see what I've been able to do with this approach (incremental load) :

Capture.PNG

iczkla
Contributor III
Contributor III
Author

Hi Omar,

Unfortunately I have no Idea how to do something like this.

My data is stored in the folder which is connected to the App and each month I load new file. 

Is there no way to identify terminated employees with script statement similiar that I used to identify new records?