Re: [HACKERS] Group By, NULL values and inconsistent behaviour. - Mailing list pgsql-hackers

From Zeugswetter Andreas DBT
Subject Re: [HACKERS] Group By, NULL values and inconsistent behaviour.
Date
Msg-id 219F68D65015D011A8E000006F8590C6010A51A7@sdexcsrv1.sd.spardat.at
Whole thread Raw
List pgsql-hackers
The following is Informix behavior:

informix@zeus:/usr/informix72> dbaccess - -
> create database nulltest in datadbs;
Database created.

> create table t1 (a int4, b char(2), c char(2));
  201: A syntax error has occurred.
Error in line 1
Near character position 20

> create table t1 (a int, b char(2), c char(2));
Table created.

> insert into t1 (a,c) values (1,'x');
1 row(s) inserted.
> insert into t1 (a,c) values (2,'x');
1 row(s) inserted.
> insert into t1 (a,c) values (3,'z');
1 row(s) inserted.
> insert into t1 (a,c) values (2,'x');
1 row(s) inserted.
> select * from t1;
          a b  c
          1    x
          2    x
          3    z
          2    x

4 row(s) retrieved.
> select b,c,sum(a) from t1 group by b,c;
b  c             (sum)

   x                 5
   z                 3

2 row(s) retrieved.
> select b,c,sum(a) from t1 group by b,c order by c;
b  c             (sum)

   x                 5
   z                 3

2 row(s) retrieved.
>


Andreas

pgsql-hackers by date:

Previous
From: Andrew Martin
Date:
Subject: Re: [HACKERS] Re: [QUESTIONS] How is PostgreSQL doing?
Next
From: Zeugswetter Andreas DBT
Date:
Subject: Re: [HACKERS] Group By, NULL values and inconsistent behaviour.