On Sun, Jun 3, 2012 at 5:56 AM, <[email protected]> wrote: > The following bug has been logged on the website: > > Bug reference: 6674 > Logged by: susan > Email address: [email protected] > PostgreSQL version: 9.1.3 > Operating system: windows vista 64b > Description: > > Hi, > when i use string_agg without DISTINCT, this function return somes empty > aggregate row result But not with DISTINCT. > To reproduce it, use Geoname database from geonames.org with this request > > SELECT iso, string_agg(DISTINCT fcode, ',') as n > FROM "GeoNames" WHERE fcode LIKE 'ADM%' GROUP BY iso ORDER BY iso ASC;
It's not clear how the behavior that you're getting is different from what you expect. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company -- Sent via pgsql-bugs mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs
