Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
alan-francis committed Apr 23, 2024
2 parents c6220a1 + f48ed7f commit 682d6cb
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion src/ahc-hrsn-elt/screening/csv.ts
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,7 @@ export class AdminDemographicCsvFileIngestSource<
-- because assurance CTEs require them
CREATE TABLE ${tableName} AS
SELECT *, row_number() OVER () as src_file_row_number, '${sessionID}' as session_id, '${sessionEntryID}' as session_entry_id
FROM read_csv_auto('${uri}', types={'SEX_AT_BIRTH_CODE': 'VARCHAR', 'ADMINISTRATIVE_SEX_CODE': 'VARCHAR', 'SEXUAL_ORIENTATION_CODE': 'VARCHAR', 'GENDER_IDENTITY_CODE': 'VARCHAR'});
FROM read_csv_auto('${uri}', types={'MPI_ID': 'VARCHAR', 'SEX_AT_BIRTH_CODE': 'VARCHAR', 'ADMINISTRATIVE_SEX_CODE': 'VARCHAR', 'SEXUAL_ORIENTATION_CODE': 'VARCHAR', 'GENDER_IDENTITY_CODE': 'VARCHAR'});
${ssr.requiredColumnNames()}
Expand Down Expand Up @@ -708,6 +708,10 @@ export class AdminDemographicCsvFileIngestSource<
${adar.onlyAllowValidRaceCodeDescriptionInAllRows("RACE_CODE_DESCRIPTION")}
${adar.onlyAllowValidPreferredLanguageCodeInAllRows("PREFERRED_LANGUAGE_CODE")}
${adar.onlyAllowValidPreferredLanguageCodeDescriptionInAllRows("PREFERRED_LANGUAGE_DESCRIPTION")}
${tr.onlyAllowedValuesInAllRows(
"PREFERRED_LANGUAGE_CODE_SYSTEM_NAME",
"'ISO','ISO 639-2','http://hl7.org/fhir/us/core/ValueSet/simple-language'"
)}
${adar.car.onlyAllowValidFieldCombinationsInAllRows("RACE_CODE","RACE_CODE_DESCRIPTION")}
${adar.car.onlyAllowValidFieldCombinationsInAllRows("PREFERRED_LANGUAGE_CODE","PREFERRED_LANGUAGE_DESCRIPTION")}
${adar.car.onlyAllowValidFieldCombinationsInAllRows("RACE_CODE_DESCRIPTION","RACE_CODE")}
Expand Down
2 changes: 1 addition & 1 deletion src/ahc-hrsn-elt/screening/orchestrate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import * as csv from "./csv.ts";
import * as excel from "./excel.ts";
import * as gov from "./governance.ts";

export const ORCHESTRATE_VERSION = "0.16.1";
export const ORCHESTRATE_VERSION = "0.16.2";

export interface FhirRecord {
PAT_MRN_ID: string;
Expand Down

0 comments on commit 682d6cb

Please sign in to comment.