Re: [BUGS] BUG #9652: inet types don't support min/max

From: Haribabu Kommi <kommi(dot)haribabu(at)gmail(dot)com>
To: Keith Fiske <keith(at)omniti(dot)com>
Cc: Andres Freund <andres(at)2ndquadrant(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Daniel O'Connor" <darius(at)dons(dot)net(dot)au>, "pgsql-bugs(at)postgresql(dot)org" <pgsql-bugs(at)postgresql(dot)org>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [BUGS] BUG #9652: inet types don't support min/max
Date: 2014-06-04 00:37:48
Message-ID: CAJrrPGdBJXZ6HQFGS5ZuM8g2N1Xvnw1qJzZhdvkjxh76L_PtNA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

On Wed, Jun 4, 2014 at 5:46 AM, Keith Fiske <keith(at)omniti(dot)com> wrote:
>
> Andres's changes on June 3rd to
> https://github.com/postgres/postgres/commits/master/src/test/regress/expected/create_function_3.out
> are causing patch v2 to fail for that regression test file.
>
> postgres $ patch -p1 -i ../inet_agg_v2.patch
> patching file src/backend/utils/adt/network.c
> patching file src/include/catalog/pg_aggregate.h
> patching file src/include/catalog/pg_proc.h
> patching file src/include/utils/builtins.h
> patching file src/test/regress/expected/create_function_3.out
> Hunk #1 FAILED at 153.
> 1 out of 1 hunk FAILED -- saving rejects to file
> src/test/regress/expected/create_function_3.out.rej
> patching file src/test/regress/expected/inet.out
> patching file src/test/regress/sql/inet.sql
>
> Otherwise it applies without any issues to the latest HEAD. I built and
> started a new instance, and I was able to test at least the basic min/max
> functionality
>
> keith=# create table test_inet (id serial, ipaddress inet);
> CREATE TABLE
> Time: 25.546 ms
> keith=# insert into test_inet (ipaddress) values ('192.168.1.1');
> INSERT 0 1
> Time: 3.143 ms
> keith=# insert into test_inet (ipaddress) values ('192.168.1.2');
> INSERT 0 1
> Time: 2.932 ms
> keith=# insert into test_inet (ipaddress) values ('127.0.0.1');
> INSERT 0 1
> Time: 1.786 ms
> keith=# select min(ipaddress) from test_inet;
> min
> -----------
> 127.0.0.1
> (1 row)
>
> Time: 3.371 ms
> keith=# select max(ipaddress) from test_inet;
> max
> -------------
> 192.168.1.2
> (1 row)
>
> Time: 1.104 ms

Thanks for the test. Patch is re-based to the latest head.

Regards,
Hari Babu
Fujitsu Australia

Attachment Content-Type Size
inet_agg_v3.patch application/octet-stream 7.1 KB

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Rainer Tammer 2014-06-04 06:03:41 Re: Problem with PostgreSQL 9.2.7 and make check on AIX 7.1
Previous Message Keith Fiske 2014-06-03 19:46:45 Re: [HACKERS] BUG #9652: inet types don't support min/max

Browse pgsql-hackers by date

  From Date Subject
Next Message Vik Fearing 2014-06-04 00:54:49 Re: idle_in_transaction_timeout
Previous Message Noah Misch 2014-06-04 00:14:55 Re: Hide 'Execution time' in EXPLAIN (COSTS OFF)