DROP PROCEDURE IF EXISTS `update_user_bio`;
DELIMITER ;;
CREATE PROCEDURE `update_user_bio` (
    IN p_bio VARCHAR(200),
    IN p_user_id INT,
    OUT p_status INT
)
proc:BEGIN
    IF p_bio = '' OR p_bio IS NULL THEN
        SET p_status = -1;
        LEAVE proc;
    END IF;
    UPDATE users SET bio = p_bio WHERE id = p_user_id;
    SET p_status = 0;
END ;;
DELIMITER ;
