postgres=# set standard_conforming_strings = off; SET postgres=# select 'a\\bcd' as f1; WARNING: nonstandard use of \\ in a string literal LINE 1: select 'a\\bcd' as f1; ^ HINT: Use the escape string syntax for backslashes, e.g., E'\\'. f1 ------- a\bcd (1 row)