Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
bcac432
commit c5eeece
Showing
5 changed files
with
81 additions
and
31 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
ALTER TABLE `classroom` CHANGE `fkid` `hash` BIGINT NULL; | ||
ALTER TABLE `instructor_documents_and_address` CHANGE `fkid` `hash` BIGINT NULL; | ||
ALTER TABLE `instructor_identification` CHANGE `fkid` `hash` BIGINT NULL; | ||
ALTER TABLE `instructor_teaching_data` CHANGE `fkid` `hash` BIGINT NULL; | ||
ALTER TABLE `instructor_variable_data` CHANGE `fkid` `hash` BIGINT NULL; | ||
ALTER TABLE `student_documents_and_address` CHANGE `fkid` `hash` BIGINT NULL; | ||
ALTER TABLE `student_enrollment` CHANGE `fkid` `hash` BIGINT NULL; | ||
ALTER TABLE `student_identification` CHANGE `fkid` `hash` BIGINT NULL; | ||
ALTER TABLE `student_enrollment` ADD COLUMN `hash_classroom` BIGINT NULL AFTER `admission_type`, ADD COLUMN `hash_student` BIGINT NULL AFTER `hash_classroom`; | ||
ALTER TABLE `instructor_teaching_data` ADD COLUMN `hash_instructor` BIGINT NULL AFTER `hash`, ADD COLUMN `hash_classroom` BIGINT NULL AFTER `hash_instructor`; | ||
ALTER TABLE `student_enrollment` | ||
ADD COLUMN `status` TINYINT(1) NULL DEFAULT NULL; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
ALTER TABLE `instructor_variable_data` | ||
CHANGE `id` `id` INT(11) NOT NULL; | ||
ALTER TABLE `instructor_documents_and_address` | ||
CHANGE `id` `id` INT(11) NOT NULL; | ||
ALTER TABLE `student_documents_and_address` | ||
CHANGE `id` `id` INT(11) NOT NULL; | ||
UPDATE classroom | ||
SET `pedagogical_mediation_type` = 1 | ||
WHERE `pedagogical_mediation_type` IS NULL AND school_year = 2017; | ||
|
||
UPDATE student_enrollment a | ||
JOIN classroom b ON(a.`classroom_fk`= b.id) | ||
SET `vehicle_type_bus` = 1 | ||
WHERE | ||
public_transport=1 AND | ||
school_year=2017; | ||
|
||
|
||
SELECT * FROM classroom | ||
WHERE | ||
school_year=2017; | ||
|
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