Re: Proper relational database? - Mailing list pgsql-general

From Manuel Gómez
Subject Re: Proper relational database?
Date
Msg-id CAJWnFaP65BmFSdt0SGrn7VimcdCVkTfte7zcnHFkO287b6PtTA@mail.gmail.com
Whole thread Raw
In response to Re: Proper relational database?  (Thomas Munro <thomas.munro@enterprisedb.com>)
Responses Re: Proper relational database?
List pgsql-general
On Sat, Apr 23, 2016 at 12:05 AM, Thomas Munro
<thomas.munro@enterprisedb.com> wrote:
> FWIW standard SQL may not allow it but Postgres does, and it's even
> possible to exclude duplicates by using an expression that references
> the whole row.

Indeed, but its semantics can be rather wonky.  Witness:

postgres=# select 1;
 ?column?
----------
        1
(1 row)

postgres=# select 1 union select 1;
 ?column?
----------
        1
(1 row)

postgres=# select;
--
(1 row)

postgres=# select union select;
--
(2 rows)

postgres=# select 1 intersect select 1;
 ?column?
----------
        1
(1 row)

postgres=# select intersect select;
--
(2 rows)


pgsql-general by date:

Previous
From: Sameer Kumar
Date:
Subject: Re: [NOVICE] Fwd: Process scheduling in postgres
Next
From: Guyren Howe
Date:
Subject: Re: Proper relational database?