Anonymous Asked in Cars &Transportation · 2 weeks ago

Why semicolon is used in MySQL?

A query need not be given all on a single line, so lengthy queries that require several lines are not a problem. mysql determines where your statement ends by looking for the terminating semicolon, not by looking for the end of the input line.


What does the semicolon do in MySQL?

A MySQL client program such as MySQL Workbench or mysql program uses the delimiter ( ; ) to separate statements and executes each statement separately. However, a stored procedure consists of multiple statements separated by a semicolon (;).

Is semicolon necessary in MySQL?

If you're writing single statements in, say, PHP and then sending them to MySQL for processing, the semicolon is optional. You ask if it "might have possible negative effects maybe during server high load, caching etc." The answer to that is 'No'.

What is the use of semicolon (;) after every command in MySQL?

By default, SQL statements are terminated with semicolons. You use a semicolon to terminate statements unless you've (rarely) set a new statement terminator.

What is use of delimiter in MySQL?

Delimiters can be used when you need to define the stored procedures, function as well as to create triggers. The default delimiter is semicolon. You can change the delimiters to create procedures and so on.

Related Questions

Relevance
Write us your question, the answer will be received in 24 hours