-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Issue #2492] Create an agency linking step for the transformation pr…
…ocess (#2529) Summary Fixes #2492 Time to review: 15 mins Changes proposed Add transform step to Agency transformation Add tests Context for reviewers As part of our transformation process, we transform agency data from the legacy system, but we want to do a second pass over agency data once in our system in order to make the agency data connect together properly. In the system, there are agencies and sub-agencies. For example, HHS is a top-level agency, and HHS-NIH11 is a subagency. We want HHS-NIH11 to point to HHS in the top_level_agency_id foreign key we setup in #2491 Determining whether an agency is a top-level or subagency is simple, a top-level agency will have no dashes, while a sub-agency will have one or more dashes in its agency code with the top-level agency being everything before the first dash. We want to iterate over the agency data in our system and attach appropriately. Additional information See attached unit test --------
- Loading branch information
1 parent
f27e988
commit 28a5a56
Showing
3 changed files
with
63 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters