The problem is that the # character is used by MySQL for line comments, so
part
of the statement was removed.
Now the type of database is checked to decide whether # comments should be
supported.
Thank you for reporting.