From: m8r-444fqh@mailinator.com
To: pgsql-bugs@postgresql.org
Subject: BUG #12877: Altitude not respected in order by and group by
Date: Wed, 18 Mar 2015 15:27:16 +0000
Message-ID: <20150318152716.2739.45328@wrigleys.postgresql.org> (raw)
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
The following bug has been logged on the website:
Bug reference: 12877
Logged by: m8r-444fqh
Email address: m8r-444fqh@mailinator.com
PostgreSQL version: 9.3.4
Operating system: centos
Description:
-- "PostgreSQL 9.3.4 on x86_64-unknown-linux-gnu, compiled by gcc (GCC)
4.4.7 20120313 (Red Hat 4.4.7-4), 64-bit"
-- Postgis: "2.1 USE_GEOS=1 USE_PROJ=1 USE_STATS=1"
create table v001 ( edge bigint, vertex geometry(PointZ,4326) );
insert into v001 values
( 19757751000,st_geomfromtext('POINT Z (-87.63394 41.8868 0)',4326)),
( 19757752000,st_geomfromtext('POINT Z (-87.63394 41.8868 0)',4326)),
( 19757763000,st_geomfromtext('POINT Z (-87.63394 41.8868 0)',4326)),
( 19791042000,st_geomfromtext('POINT Z (-87.63394 41.8868 -1)',4326)),
( 721078263000,st_geomfromtext('POINT Z (-87.63394 41.8868 0)',4326)),
( 721078269000,st_geomfromtext('POINT Z (-87.63394 41.8868 -1)',4326));
-- 1.Query, fails to sort altitude:
select edge, st_astext( vertex ) from v001
order by vertex,edge;
-- 1.Results:
-- 19757751000;"POINT Z (-87.63394 41.8868 0)"
-- 19757752000;"POINT Z (-87.63394 41.8868 0)"
-- 19757763000;"POINT Z (-87.63394 41.8868 0)"
-- 19791042000;"POINT Z (-87.63394 41.8868 -1)"
-- 721078263000;"POINT Z (-87.63394 41.8868 0)"
-- 721078269000;"POINT Z (-87.63394 41.8868 -1)"
-- 2.Query, fails to respect altitude:
select array_agg( edge ) as edges, st_astext(vertex) from v001
group by vertex;
-- 2.Results:
--
"{19757751000,19757752000,19757763000,19791042000,721078263000,721078269000}";"POINT
Z (-87.63394 41.8868 0)"
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: m8r-444fqh@mailinator.com
Subject: Re: BUG #12877: Altitude not respected in order by and group by
In-Reply-To: <20150318152716.2739.45328@wrigleys.postgresql.org>
References: <20150318152716.2739.45328@wrigleys.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox