Postgresql sql scripts containing '#' fail on macos:m1 yet work on macos:x86

hi -

validating our java/pg/liquibase stack on a new macos:m1 that works as expected on (linux,macosx):x86

error is:

  • Caused by: org.postgresql.util.PSQLException: ERROR: syntax error at or near “#”

exemplary sql script:

# note: this is a note
insert into ...

q: any thoughts as to why we would encounter this issue when deploying a working x86 stack on macos:m1

in bootstrapping the new dev mbp i did run into some interesting zsh globbing situations that are unique to this install as well. can’t entirely see why that would be related to what we are encountering at the lb/db/jdbc/sql layer though.

thx in advance,

  • james

[update] i would like to resolve/remove this issue as given some time to think about this situation i suspect the errant ‘#’ chars were added to the liquibase scripts after they were applied via liquibase and as such not valid.

Hi @jwtodd , are you using the liquibase CLI, docker container, maven, something else?

ello … gradle with liquibase wired into the app-at-start-time

I hesitate to say this since you said that the script used to work, but I would change the comment from:

# note: this is a note
insert into ...

to:

-- note: this is a note
insert into ...

or

/* note: this is a note */
insert into ...