HMIS / LSASampleCode

Longitudinal System Analysis (LSA) Sample Code and Documentation
22 stars 10 forks source link

Spec and Sample Code: Section 7.4 DisabilityStatus logic for LSAExit #1153

Closed nataliesus closed 10 months ago

nataliesus commented 11 months ago

Hi @MollyMcEvilley ,

I have a few questions about recent updated related to 7.4 section.

Spec: image

Sample Code: image

My concerns:

  1. Spec: "Set to 99 if..." does not take into account that DisabilityStatus could be set to 1 because of prev condition;
  2. Sample Code:
    • we use GROUP BY, so we need to rewrite the CASE condition to work for "if the value is X for any EnrollmentID";
    • maybe the CASE should be rewritten to follow the Spec so if there are 2 enrollments with 0, and NULL values correspondently, then, according to Spec, DisabilityStatus should be 99. But in Sample Code DisabilityStatus result is 0.

Could you please take a look?

Thank you! Natalie

P.S. Just in case status for https://github.com/HMIS/LSASampleCode/issues/1135 should be changed.

MollyMcEvilley commented 10 months ago

I re-ordered the criteria in the specs and re-worked the sample code accordingly. I don't think I accounted for the possibility that there might be more than one EnrollmentID per PersonalID for a given HouseholdID.

image