mirror of
https://github.com/opelly27/WinStudentGoalTracker.git
synced 2026-05-20 12:17:35 +00:00
20 lines
607 B
SQL
20 lines
607 B
SQL
DELIMITER ;;
|
|
CREATE DEFINER=`root`@`%` PROCEDURE `sp_Student_Update`(
|
|
IN p_id_student CHAR(36),
|
|
IN p_identifier VARCHAR(50),
|
|
IN p_program_year INT,
|
|
IN p_enrollment_date DATE,
|
|
IN p_expected_grad DATE
|
|
)
|
|
BEGIN
|
|
UPDATE student
|
|
SET
|
|
identifier = COALESCE(p_identifier, identifier),
|
|
program_year = COALESCE(p_program_year, program_year),
|
|
enrollment_date = COALESCE(p_enrollment_date, enrollment_date),
|
|
expected_grad = COALESCE(p_expected_grad, expected_grad)
|
|
WHERE id_student = p_id_student;
|
|
SELECT ROW_COUNT() AS rows_affected;
|
|
END;;
|
|
DELIMITER ;
|