ERROR: syntax error at or near ":" - Mailing list pgsql-general

From Graham Leggett
Subject ERROR: syntax error at or near ":"
Date
Msg-id D60E06BC-D18B-4AB9-A70E-AF1326CA7EB0@sharp.fm
Whole thread Raw
Responses Re: ERROR: syntax error at or near ":"
Re: ERROR: syntax error at or near ":"
Re: ERROR: syntax error at or near ":"
List pgsql-general
Hi all,

I have a text file, and I need to update the value of an element in a table with the contents of this text file.
Followingthe instructions at
http://stackoverflow.com/questions/10968039/postgresql-inserting-value-of-a-column-from-a-fileI tried this, but get the
errorbelow, which I do not understand. 

Can anyone explain what might be going wrong, and what I should do instead?

patricia=# \set content `cat /tmp/certificates.txt`
patricia=# update property set value = :'content' where key = 'patricia.home.security.cacerts';
ERROR:  syntax error at or near ":"
LINE 1: update property set value = :'content' where key = 'patricia...
                                    ^

Regards,
Graham
--


Attachment

pgsql-general by date:

Previous
From: ning chan
Date:
Subject: Re: WAL_DEBUG
Next
From: Greg Williamson
Date:
Subject: Re: ERROR: syntax error at or near ":"