Re: How to keep the last row of a data set?

From: John R Pierce <pierce(at)hogranch(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: How to keep the last row of a data set?
Date: 2012-12-13 20:22:49
Message-ID: 50CA3919.1090208@hogranch.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 12/13/2012 5:32 AM, seiliki(at)so-net(dot)net(dot)tw wrote:
> I am trying to implement a mechanism that prohibits the last row of a data set from being deleted.
>
> CREATE TABLE t1 (c1 INTEGER,c2 INTEGER, PRIMARY KEY (c1,c2));
>
> INSERT INTO t1 VALUES (1,1),(1,2),(1,3),(2,1),(2,2),(2,3);

Which row is the last row? relations are sets, not ordered lists.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Edson Richter 2012-12-13 21:00:09 Re: How to keep the last row of a data set?
Previous Message Edson Richter 2012-12-13 19:54:46 XML Schema for PostgreSQL database