-
Notifications
You must be signed in to change notification settings - Fork 19
Migration/amm 2035 #70
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
SauravBizbRolly
wants to merge
18
commits into
main
Choose a base branch
from
migration/AMM_2035
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
99cbd94
Dynamic Form for db changes
SauravBizbRolly 32f3642
Dynamic Form for db changes
SauravBizbRolly aa048ce
Dynamic Form for db changes
SauravBizbRolly 1f84119
Dynamic Form for db changes
SauravBizbRolly dbec5e5
Dynamic Form for db changes
SauravBizbRolly 80f8a02
Dynamic Form for db changes
SauravBizbRolly b63cf34
Merge pull request #63 from toarunmishra/migration/dynamic_form_db_chβ¦
SauravBizbRolly ec49166
soft-delete AMM-2040,AMM-2060
SauravBizbRolly f05d397
soft-delete AMM-2040,AMM-2060
SauravBizbRolly 0e13f53
dynamic form tables AMM-1877
SauravBizbRolly 4706783
soft-delete AMM-2040,AMM-2060
SauravBizbRolly fa9b21e
dynamic form tables AMM-1877
SauravBizbRolly 2f208bc
dynamic form tables AMM-1877
SauravBizbRolly 0c3719a
dynamic form tables AMM-1877
SauravBizbRolly 1ef9f6e
AMM-2035
SauravBizbRolly 944149c
AMM-2035
SauravBizbRolly c71b048
rename version
SauravBizbRolly 17757d6
update version name
SauravBizbRolly File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,37 @@ | ||
| USE db_iemr; | ||
|
|
||
| CREATE TABLE IF NOT EXISTS `anc_counselling_care` ( | ||
| `id` bigint NOT NULL AUTO_INCREMENT, | ||
| `beneficiary_id` bigint NOT NULL, | ||
| `visit_date` date DEFAULT NULL, | ||
| `home_visit_date` date NOT NULL, | ||
| `anc_visit_id` bigint NOT NULL, | ||
| `created_at` datetime DEFAULT CURRENT_TIMESTAMP, | ||
| `updated_at` datetime DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
| `select_all` tinyint(1) DEFAULT '0', | ||
| `swelling` tinyint(1) DEFAULT '0', | ||
| `high_bp` tinyint(1) DEFAULT '0', | ||
| `convulsions` tinyint(1) DEFAULT '0', | ||
| `anemia` tinyint(1) DEFAULT '0', | ||
| `reduced_fetal_movement` tinyint(1) DEFAULT '0', | ||
| `age_risk` tinyint(1) DEFAULT '0', | ||
| `child_gap` tinyint(1) DEFAULT '0', | ||
| `short_height` tinyint(1) DEFAULT '0', | ||
| `pre_preg_weight` tinyint(1) DEFAULT '0', | ||
| `bleeding` tinyint(1) DEFAULT '0', | ||
| `miscarriage_history` tinyint(1) DEFAULT '0', | ||
| `four_plus_delivery` tinyint(1) DEFAULT '0', | ||
| `first_delivery` tinyint(1) DEFAULT '0', | ||
| `twin_pregnancy` tinyint(1) DEFAULT '0', | ||
| `c_section_history` tinyint(1) DEFAULT '0', | ||
| `pre_existing_disease` tinyint(1) DEFAULT '0', | ||
| `fever_malaria` tinyint(1) DEFAULT '0', | ||
| `jaundice` tinyint(1) DEFAULT '0', | ||
| `sickle_cell` tinyint(1) DEFAULT '0', | ||
| `prolonged_labor` tinyint(1) DEFAULT '0', | ||
| `malpresentation` tinyint(1) DEFAULT '0', | ||
| `user_id` int DEFAULT NULL, | ||
| `created_by` varchar(250) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, | ||
| `updated_by` varchar(250) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, | ||
| PRIMARY KEY (`id`) | ||
| ) ; | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
π§© Analysis chain
π Script executed:
fd -t f "V67__AMM_2035.sql" src/main/resources/db/migrationRepository: PSMRI/AMRIT-DB
Length of output: 114
π Script executed:
Repository: PSMRI/AMRIT-DB
Length of output: 1879
π Script executed:
Repository: PSMRI/AMRIT-DB
Length of output: 1058
π Script executed:
Repository: PSMRI/AMRIT-DB
Length of output: 40
π Script executed:
grep -r "fk_anc_counselling_care" src/main/resources/db/migration/dbiemr/Repository: PSMRI/AMRIT-DB
Length of output: 40
π Script executed:
grep -r "CONSTRAINT.*anc_visit" src/main/resources/db/migration/dbiemr/Repository: PSMRI/AMRIT-DB
Length of output: 40
π Script executed:
Repository: PSMRI/AMRIT-DB
Length of output: 197
π Script executed:
Repository: PSMRI/AMRIT-DB
Length of output: 114
π Script executed:
ls -1 src/main/resources/db/migration/dbiemr/ | wc -lRepository: PSMRI/AMRIT-DB
Length of output: 60
π Script executed:
grep -n "FOREIGN KEY" src/main/resources/db/migration/dbiemr/V67__AMM_2035.sqlRepository: PSMRI/AMRIT-DB
Length of output: 40
π Script executed:
Repository: PSMRI/AMRIT-DB
Length of output: 914
Add a foreign key constraint for
anc_visit_idto enforce referential integrity.The
anc_visit_idcolumn at line 8 is declared asNOT NULLbut lacks a foreign key constraint. Thet_anc_visittable exists in V1__DB_IEMR.sql with a compatibleidcolumn type (bigint). Without the constraint, orphaned records and referential integrity violations are possible.Suggested change
π€ Prompt for AI Agents