mysql not recognizing DELIMITER
Hey, so I am having trouble getting the DELIMITER to work for stored procedures and mysql triggers.
I have tried type DELIMITER, like my course demonstrates, and the word does not change colours like mysql would for a keyword, and the code does not execute. -- @DELIMITER does not work either.
It runs the DROP PROCEDURES command with a warning that there are no procedures with that name, and the rest of the code shows error 1064 (at 1000; it says missing ';', and at END$$, it says END invalid, expecting EOF, ALTER...)I tried typing -- @DELIMITER instead, and this does not work either. Here's an example of a code that doesn't run:
USE employees;
DROP PROCEDURE IF EXISTS select_employees;
-- @DELIMITER $$
CREATE PROCEDURE select_employees()
BEGIN
SELECT * FROM employees
LIMIT 1000;
END$$
-- @DELIMITER ;
I have tried reaching out in the help section in my course platform, but have not received a helpful response (they suggested that I could be missing a semicolon somewhere else in my code, and that I would fix the problem with END by following it directly with the delimiter $$). SO, I'm curious about what I'm missing!
Subject
Written By
Posted
mysql not recognizing DELIMITER
February 09, 2024 11:23AM
February 09, 2024 05:09PM
Sorry, only registered users may post in this forum.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.