I want to get the info from table s via inputting specific student name.
s
Code goes like this:
delimiter // `CREATE PROCEDURE get_info_hujiamin (IN sn_input VARCHAR) BEGIN SELECT * FROM s WHERE s.sn=sn_input; END` //
Do query like below: here you haven't added length of VARCHAR
DELIMITER // CREATE PROCEDURE GetOfficeByCountry(IN countryName VARCHAR(255)) BEGIN SELECT * FROM offices WHERE country = countryName; END // DELIMITER ;
You can also refer My SQL Procedure
Do query like below: here you haven't added length of VARCHAR
You can also refer My SQL Procedure