-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #646 from bcgov/grad-release
Grad release 1.18.0
- Loading branch information
Showing
8 changed files
with
98 additions
and
28 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
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
7 changes: 7 additions & 0 deletions
7
api/src/main/resources/db/migration/1.0/V1.0.62__DDL-ALTER_TABLES-for-institution-api.sql
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,7 @@ | ||
ALTER TABLE EDW_GRADUATION_SNAPSHOT ADD SCHOOL_OF_RECORD_ID RAW(16); | ||
|
||
ALTER TABLE GRADUATION_STUDENT_RECORD ADD SCHOOL_OF_RECORD_ID RAW(16); | ||
ALTER TABLE GRADUATION_STUDENT_RECORD ADD SCHOOL_AT_GRADUATION_ID RAW(16); | ||
|
||
ALTER TABLE GRADUATION_STUDENT_RECORD_HISTORY ADD SCHOOL_OF_RECORD_ID RAW(16); | ||
ALTER TABLE GRADUATION_STUDENT_RECORD_HISTORY ADD SCHOOL_AT_GRADUATION_ID RAW(16); |
42 changes: 42 additions & 0 deletions
42
...main/resources/db/migration/1.0/V1.0.63__DDL-REPLACE_VIEW-REPORT_GRAD_STUDENT_DATA_VW.sql
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,42 @@ | ||
DROP VIEW REPORT_GRAD_STUDENT_DATA_VW; | ||
|
||
CREATE OR REPLACE VIEW REPORT_GRAD_STUDENT_DATA_VW AS | ||
SELECT | ||
A1.GRADUATION_STUDENT_RECORD_ID, | ||
A1.SCHOOL_OF_RECORD MINCODE, | ||
A1.SCHOOL_AT_GRADUATION MINCODE_AT_GRAD, | ||
SUBSTR(A1.SCHOOL_OF_RECORD, 0, 3) DISTRICT_CODE, | ||
SUBSTR(A1.SCHOOL_AT_GRADUATION, 0, 3) DISTRICT_CODE_AT_GRAD, | ||
A1.STUDENT_STATUS_CODE STATUS, | ||
A1.UPDATE_DATE, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.gradStudent.pen' RETURNING VARCHAR2(10) DEFAULT 'error' ON ERROR) PEN, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.gradStudent.legalFirstName' RETURNING VARCHAR2(64) DEFAULT 'error' ON ERROR) FIRST_NAME, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.gradStudent.legalMiddleNames' RETURNING VARCHAR2(64) DEFAULT 'error' ON ERROR) MIDDLE_NAME, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.gradStudent.legalLastName' RETURNING VARCHAR2(64) DEFAULT 'error' ON ERROR) LAST_NAME, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.gradStudent.studentGrade' RETURNING VARCHAR2(64) DEFAULT 'error' ON ERROR) GRADE, | ||
--JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.gradStudent.studentStatus' RETURNING VARCHAR2(64) DEFAULT 'error' ON ERROR) STATUS, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.school.districtName' RETURNING VARCHAR2(128) DEFAULT 'error' ON ERROR) DISTRICT_NAME, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.school.schoolName' RETURNING VARCHAR2(128) DEFAULT 'error' ON ERROR) SCHOOL_NAME, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.school.address1' RETURNING VARCHAR2(128) DEFAULT 'error' ON ERROR) SCHOOL_ADDRESS1, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.school.address2' RETURNING VARCHAR2(128) DEFAULT 'error' ON ERROR) SCHOOL_ADDRESS2, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.school.city' RETURNING VARCHAR2(128) DEFAULT 'error' ON ERROR) SCHOOL_CITY, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.school.provCode' RETURNING VARCHAR2(128) DEFAULT 'error' ON ERROR) SCHOOL_PROVINCE, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.school.countryName' RETURNING VARCHAR2(128) DEFAULT 'error' ON ERROR) SCHOOL_COUNTRY, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.school.postal' RETURNING VARCHAR2(128) DEFAULT 'error' ON ERROR) SCHOOL_POSTAL, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.gradProgram.programCode' RETURNING VARCHAR2(64) DEFAULT 'error' ON ERROR) PROGRAM_CODE, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.gradProgram.programName' RETURNING VARCHAR2(128) DEFAULT 'error' ON ERROR) PROGRAM_NAME, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.gradStatus.programCompletionDate' RETURNING VARCHAR2(10) DEFAULT 'error' ON ERROR) PROGRAM_COMPLETION_DATE, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.gradStatus.honoursStanding' RETURNING VARCHAR2(10) DEFAULT 'error' ON ERROR) HONORS_STANDING, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.graduated' RETURNING VARCHAR2(10) DEFAULT 'error' ON ERROR) IS_GRADUATED, | ||
JSON_VALUE(A1.STUDENT_GRAD_DATA, '$.studentCertificatesTranscript.transcriptTypeCode' RETURNING VARCHAR2(16) DEFAULT '' ON ERROR) TRANSCRIPT_TYPE_CODE, | ||
JSON_QUERY(A1.STUDENT_GRAD_DATA, '$.studentCertificatesTranscript.certificateTypeCodes') CERTIFICATE_TYPE_CODES, | ||
JSON_QUERY(A1.STUDENT_GRAD_DATA, '$.studentCourses.studentCourseList.courseName' WITH WRAPPER) STUDENT_COURSES, | ||
--DECODE(LENGTH(JSON_QUERY(A1.STUDENT_GRAD_DATA, '$.studentCourses.studentCourseList.courseName' WITH CONDITIONAL WRAPPER)), 0, 'N', 'Y') HAS_STUDENT_COURSES, | ||
JSON_QUERY(A1.STUDENT_GRAD_DATA, '$.nonGradReasons') NON_GRAD_REASONS | ||
FROM | ||
API_GRAD_STUDENT.GRADUATION_STUDENT_RECORD A1 | ||
WHERE A1.STUDENT_STATUS_CODE NOT IN ('TER', 'DEC') | ||
|
||
; | ||
|
||
|
26 changes: 26 additions & 0 deletions
26
...sources/db/migration/1.0/V1.0.64__DDL-REPLACE_VIEW-REPORT_GRAD_SCHOOL__DISTRICT_YE_VW.sql
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,26 @@ | ||
CREATE OR REPLACE VIEW REPORT_GRAD_SCHOOL_YE_VW AS | ||
SELECT | ||
COUNT(GRADUATION_STUDENT_RECORD_ID) STUD_NUM, | ||
SUBSTR(DECODE(A1.SCHOOL_AT_GRADUATION, NULL, A1.SCHOOL_OF_RECORD, A1.SCHOOL_AT_GRADUATION), 0, 3) MINCODE | ||
FROM | ||
GRADUATION_STUDENT_RECORD A1 | ||
WHERE | ||
A1.PROGRAM_COMPLETION_DATE is null | ||
AND A1.STUDENT_STATUS_CODE = 'CUR' | ||
AND (A1.STUDENT_GRADE ='AD' or A1.STUDENT_GRADE='12') | ||
GROUP BY SUBSTR(DECODE(A1.SCHOOL_AT_GRADUATION, NULL, A1.SCHOOL_OF_RECORD, A1.SCHOOL_AT_GRADUATION), 0, 3) | ||
ORDER BY 1 DESC; | ||
|
||
CREATE OR REPLACE VIEW REPORT_GRAD_DISTRICT_YE_VW AS | ||
SELECT DISTINCT | ||
SUBSTR(DECODE(A1.SCHOOL_AT_GRADUATION, NULL, A1.SCHOOL_OF_RECORD, A1.SCHOOL_AT_GRADUATION), 0, 3) MINCODE | ||
FROM | ||
GRADUATION_STUDENT_RECORD A1 | ||
WHERE | ||
A1.PROGRAM_COMPLETION_DATE is null | ||
AND A1.STUDENT_STATUS_CODE = 'CUR' | ||
AND (A1.STUDENT_GRADE ='AD' or A1.STUDENT_GRADE='12') | ||
GROUP BY SUBSTR(DECODE(A1.SCHOOL_AT_GRADUATION, NULL, A1.SCHOOL_OF_RECORD, A1.SCHOOL_AT_GRADUATION), 0, 3) | ||
ORDER BY 1 DESC; | ||
|
||
|
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