A pathological example:
-- a weird comment
y from t;
The multiline handling preserves the comment but strips
out the newlines, so the JDBC driver sees everything
after the -- as comment. This will lead to a syntax
error from the truncated "select x,". (If you use the
non-standard # comment introducer, you'll instead get a
syntax error from JDBC drivers that don't accept that).
I'm going to fix this by stripping out comments as the
multiline SQL string is accumulated.