array problem with double quotes - Mailing list pgsql-sql

From Olivier Leprêtre
Subject array problem with double quotes
Date
Msg-id 5bc34756.1c69fb81.22161.822d@mx.google.com
Whole thread Raw
Responses Re: array problem with double quotes  (Joe Conway <mail@joeconway.com>)
List pgsql-sql

Hi,

 

Is there a way to create arrays without postgres adding double quotes when there are commas ?

 

select v1,v2 from (values ('co',array[['ab'],['ab,da']])) sub (v1,v2)

 

returns

"v1";"v2"

"co";"{{ab},{"ab,da"}}"

 

where I wanted

 

"co";"{{ab},{ab,da}}"

 

to match with the result of an array_agg which returns {ab,da}

 

In my case I then can't have {ab,da} @> {"ab,da"}

 

 

Thanks,

 

Olivier


Garanti sans virus. www.avast.com

pgsql-sql by date:

Previous
From: Stephen Frost
Date:
Subject: Re: remove from list?
Next
From: Joe Conway
Date:
Subject: Re: array problem with double quotes