BUG #14080: JSONB order changes when using json_pretty()

From: jack(at)fastly(dot)com
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #14080: JSONB order changes when using json_pretty()
Date: 2016-04-08 22:43:45
Message-ID: 20160408224345.15199.8059@wrigleys.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 14080
Logged by: Jack
Email address: jack(at)fastly(dot)com
PostgreSQL version: 9.5.2
Operating system: Mac OSX
Description:

while looking though datasets I noticed json_pretty is retuning a different
record.

This query will return an id that I expect and other defendant queries seem
to work
```
select jsonb_array_elements(details->'version'->'domains'), id from services
order by id limit 1 offset 400;
```

This query returns a random record both the id and the json are valid they
are just the wrong one.

```
select jsonb_pretty(details->'version'->'domains'), id from services order
by id limit 1 offset 400;
```

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Phillip Couto 2016-04-08 22:53:49 Re: BUG #14079: Issues with query
Previous Message hector.bejarano 2016-04-08 21:47:43 BUG #14079: Issues with query