On Thu, Aug 17, 2006 at 05:05:00PM +0400, Ilja Golshtein wrote: > Is there any way to have psql variable in apostrophes? > > The idea is to do something like this > > \set var 'some value' > insert into aaa values(:var)
test=> \set var '\'some value\'' test=> insert into aaa values (:var); INSERT 0 1 test=> select * from aaa; val ------------ some value (1 row) -- Michael Fuhr ---------------------------(end of broadcast)--------------------------- TIP 2: Don't 'kill -9' the postmaster