Sunday, June 18, 2017

Week 3: Finally Some Relief

I am very happy to say that the problem that I have aforementioned in my 2nd week's blog post, has already been solved. 

In my 1st week's blog post I did mention the tasks that I should complete withinin this summer. The task I have completed in this week is,
Once the user has selected the old report, we must find the date it had run and fetch the patients' records which are either added or updated after that date. This is done by comparing patientmatching_report.created_on AND patient.date_added OR patient.date_changed table fields.
 This is how it was mentioned in the post.

There were two classes that I should change to get the job done,
Changes related to those classes can be found here and here respectively.


Things I want to highlight


According to my target I should maintain a single report per a strategy therefore it is necessary to have unique name for a strategy. For example a strategy having the name "family_name block" will be named as as "dedup-incremental-report-family_name block". 

How did I Fetch the Patient Records ?
It is straightforward. As I have to fetch the patients' records which are either added or updated after the date of the report generated, I had to add a restriction to the criteria which was created by hibernate createCriteria(Patient.class).


Only for a Single Strategy
In order to achieve the above part it must be ensured that this only happens when the user selects a single strategy. This part was done considering the user's selection. If there is only a single strategy the above part will get activated. I have shown in the below, how the code appears to be in the class MatchingReportUtils.java inside the method InitScratchTable


No comments:

Post a Comment