http://www.perlmonks.org?node_id=992445


in reply to Re^2: Multiple SQL statements in DBI
in thread Multiple SQL statements in DBI

It's the mysql client library C API that introduces the limitation:

Executes the SQL statement pointed to by the null-terminated string stmt_str. Normally, the string must consist of a single SQL statement without a terminating semicolon (“;”) or \g.

Special steps must be taken to allow execution of multiple statements, and seems to be new in version 5.0.

The Postgresql C API doesn't follow that model, but makes another interesting remark:

Note however that the returned PGresult structure describes only the result of the last command executed from the string

which makes it less useful to run multiple statements in a single API call.