Search Postgresql Archives

Re: Inserting string with a " into an array using {} syntax ... possible?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In response to Pavel Stehule <pavel.stehule@xxxxxxxxx>:

> Hello
> 
> try
> postgres=# SELECT ARRAY['text "for you" some'];
>            array
> ---------------------------
>  {"text \"for you\" some"}
> (1 row)

Thanks, and I'm aware of that, but it doesn't answer the original
question.  The code I'm writing is back-end code that other developers
will use to submit queries.

I don't have the luxury of changing their queries from {} syntax to
[] syntax at runtime.  However, if this is something that can't be
done with {}, I can catch it during data validation and throw a useful
error.

-- 
Bill Moran
http://www.potentialtech.com
http://people.collaborativefusion.com/~wmoran/

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux