edits.seer.internal.rules.IFN6154.xml Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of validation-edits-seer Show documentation
Show all versions of validation-edits-seer Show documentation
Java implemenation of the SEER edits.
<rule id="IFN6154" name="Mets at DX, Appendix, EOD Mets (SEER)" tag="N6154" java-path="lines.line" category="inter-field" depends="Year_of_Diagnosis"> <expression><![CDATA[if (line.dateOfDiagnosisYear == null || line.dateOfDiagnosisYear < '2021' || line.typeOfReportingSource == '7') return true if (line.eodMets == null || line.schemaId == null || (line.schemaId != '00190' && line.schemaId != '09190')) return true if (line.metsAtDxBone == null && line.metsAtDxBrain == null && line.metsAtDxDistantLn == null && line.metsAtDxLiver == null && line.metsAtDxLung == null && line.metsAtDxOther == null) return true boolean metsAtDxBoneCondition = line.metsAtDxBone == null || ['0','9'].contains(line.metsAtDxBone) boolean metsAtDxBrainCondition = line.metsAtDxBrain == null || ['0','9'].contains(line.metsAtDxBrain) boolean metsAtDxDistantLnCondition = line.metsAtDxDistantLn == null || ['0','9'].contains(line.metsAtDxDistantLn) boolean metsAtDxLiverCondition = line.metsAtDxLiver == null || ['0','9'].contains(line.metsAtDxLiver) boolean metsAtDxLungCondition = line.metsAtDxLung == null || ['0','9'].contains(line.metsAtDxLung) boolean metsAtDxOtherCondition = line.metsAtDxOther == null || ['0','9'].contains(line.metsAtDxOther) if ((line.metsAtDxOther == '1' && metsAtDxBoneCondition && metsAtDxBrainCondition && metsAtDxDistantLnCondition && metsAtDxLiverCondition && metsAtDxLungCondition) && !['10','30','50'].contains(line.eodMets)) return false if (line.metsAtDxOther == '2' && metsAtDxDistantLnCondition && metsAtDxBoneCondition && metsAtDxBrainCondition && metsAtDxLiverCondition && metsAtDxLungCondition && !['30','50'].contains(line.eodMets)) return false if (line.metsAtDxDistantLn == '1' && metsAtDxBoneCondition && metsAtDxBrainCondition && metsAtDxLiverCondition && metsAtDxLungCondition && metsAtDxOtherCondition && line.eodMets != '40') return false if (((line.metsAtDxDistantLn == '1' && (line.metsAtDxOther == '1' || line.metsAtDxOther == '2')) || (line.metsAtDxBone == '1' || line.metsAtDxBrain == '1' || line.metsAtDxLiver == '1' || line.metsAtDxLung == '1')) && line.eodMets != '50') return false if (line.eodMets == '10' && line.metsAtDxOther != '1') return false if (line.eodMets == '30' && line.metsAtDxOther != '1' && line.metsAtDxOther != '2') return false if (line.eodMets == '40' && line.metsAtDxDistantLn != '1') return false return true]]></expression> <message>Mets at DX fields conflict with EOD Mets for Appendix</message> <description><![CDATA[This edit verifies that Mets at DX-Bone, Mets at DX-Brain, Mets at DX-Distant LN, Mets at DX-Liver, Mets at DX-Lung, and Mets at DX-Other are coded consistently with EOD Mets for Schema ID 00190, Appendix. 1. The edit is skipped for the following conditions: a. Date of Diagnosis before 2021, blank (unknown), or invalid. b. Schema ID is blank or not 00190 or 09190 c. Mets at DX-Bone, Mets at DX-Brain, Mets at DX-Distant LN, Mets at DX-Liver, Mets at DX-Lung, and Mets at DX-Other are all blank d. EOD Mets is blank e. Type of Reporting Source is 7 (Death Certificate Only) 2. If Mets at DX-Other = 1 and (Mets at DX-Bone = 0,9, Mets at DX-Brain = 0,9, Mets at DX-Distant LN = 0,9, Mets at DX-Liver= 0,9, Mets at DX-Lung = 0,9, or fields are empty) then EOD Mets must = 10, 30, or 50 3. If Mets at DX-Other = 2 and (Mets at DX-Bone = 0, 9, Mets at DX-Brain = 0, 9, Mets at DX-Distant LN = 0, 9, Mets at DX-Liver = 0, 9, Mets at DX-Lung = 0, 9, or fields are empty) then EOD Mets must = 30 or 50 4. If Mets at DX-Distant LN = 1 and (Mets at DX-Bone = 0,9, Mets at DX-Brain = 0,9, Mets at DX-Liver= 0,9, Mets at DX-Lung = 0,9, and Mets at DX-Other = 0,9, or fields are empty) then EOD Mets must = 40 5. If Mets at DX-Distant LN = 1 and Mets at DX-Other = 1 or 2, or (Mets at DX-Bone = 1, or Mets at DX-Brain = 1, or Mets at DX-Liver= 1, or Mets at DX-Lung = 1) then EOD Mets must = 50 6. If EOD Mets = 10 (intraperitoneal acellular mucin) then Mets at DX-Other must = 1 7. If EOD Mets = 30 (intraperitoneal metastasis) then Mets at DX-Other must = 1 or 2 8. If EOD Mets = 40 (Distant lymph nodes) then Mets at DX-Distant LN must = 1]]></description> <history> <event version="SE21-021-04" user="beverung" date="2021-04-14" ref="68608">Edit created.</event> <event version="SE22-022-08" user="secristc" date="2022-06-23" ref="69011">Updated error message.</event> <event version="SE23-023-01" user="cooki" date="2023-02-09" ref="69139">Updated several conditions to match new NAACCR translated edit.</event> </history> </rule>