1
0
mirror of https://github.com/pcvolkmer/mv64e-onkostar-data.git synced 2025-07-02 02:22:54 +00:00

chore: to not throw exception on missing GRZ

This commit is contained in:
2025-06-21 16:40:33 +02:00
parent 47449bbaa3
commit 5003737d2c

View File

@ -6,7 +6,6 @@ import dev.pcvolkmer.mv64e.mtb.GenderCodingCode;
import dev.pcvolkmer.mv64e.mtb.Patient;
import dev.pcvolkmer.onco.datamapper.ResultSet;
import dev.pcvolkmer.onco.datamapper.datacatalogues.PatientCatalogue;
import dev.pcvolkmer.onco.datamapper.exceptions.DataAccessException;
/**
* Mapper class to load and map diagnosis data from database table 'dk_dnpm_kpa'
@ -65,7 +64,7 @@ public class PatientDataMapper implements DataMapper<Patient> {
private String getMunicipalityCode(final ResultSet data) {
var gkz = data.getString("GKZ");
if (gkz == null || gkz.trim().length() != 8) {
throw new DataAccessException("Municipality code not found");
return null;
}
return gkz.substring(0, 5);
}