Oracle uses the SQL standard syntax for simple comments: dash-dash starts a comment, the rest of the line is a comment.
MariaDB uses non-standard syntaxt: dash-dash-space starts a comment. This is an example of a valid script:
If I remove the space character after "--", it returns a syntax error:
That was an intentional design in early MySQL versions:
We should add an option to make dash-dash without an extra space start a comment, as it makes migration from Oracle difficult.
Perhaps, a new flag in sql_mode or old_mode can solve the issue.