Lord Elrond
Lord Elrond

Reputation: 16032

What is the equivalent to the MySQL DELIMITER in Azure?

What is the equivalent to the MySQL DELIMITER statement using Azure?

For example, in MySQL you can do this:

DELIMITER $$

CREATE TRIGGER foo 
AFTER INSERT ON table1
FOR EACH ROW BEGIN

IF (some condition) THEN
    SELECT * FROM table2;
END IF;

END $$

DELIMITER ;

Upvotes: 0

Views: 240

Answers (1)

George Chen
George Chen

Reputation: 14334

Actually from the Azure MySQL doc, you could know it's still MySQL Server engine and support The MySQL Command-Line Client to manage MySQL. So the MySQL statement is also applicable for Azure MySQL.

I test with CMD to connect Azure MySQL.

1.Check the default properties with status. You could find the Using delimiter is ; now.

enter image description here

2.Use DELIMITER // to change the delimiter. Then check the status.

enter image description here

So DELIMITER does apply to Azure MySQL.

Upvotes: 1

Related Questions