Re: Foreign Keys as first class citizens at design time? - Mailing list pgsql-general

From Stephen Feyrer
Subject Re: Foreign Keys as first class citizens at design time?
Date
Msg-id op.x3cp1pwwx77qtv@sveta.home.org
Whole thread Raw
In response to Re: Foreign Keys as first class citizens at design time?  ("David G. Johnston" <david.g.johnston@gmail.com>)
List pgsql-general
Hi,

I agree with each of the points you've made.  The idea here is meant as an extension of what is already available.  So yes, this is intended to answer the questions of the designer's original model.  The consideration being that you design your database and the underlying logic of your decision are already built in.  Then when querying that database to perform mundane day to day business tasks your query set is simple and easy to build.

I don't see why this should detract from the idea of a free form query being built using the existing tools to answer a new question which may be entirely unrelated to the original models purpose.  This just couldn't work independently of the current SQL feature set.

Additionally, this something which has not really been touched on, this allows a form of iterative structure in a one line query.


On Fri, 14 Aug 2015 03:52:28 +0100, David G. Johnston <david.g.johnston@gmail.com> wrote:

On Thu, Aug 13, 2015 at 7:26 PM, Stephen Feyrer <stephen.feyrer@btinternet.com> wrote:
When we design databases, invariably, normally we design the queries at the same time. 

​Well this may be true to an extent well implemented models have the ability to answer questions (queries) the original designer never thought of or that were not important at the time.​

​As for the rest - ​invest in a good graphical query builder (or write one if the existing choices are insufficient).

David J.




--
Kind regards


Stephen Feyrer

pgsql-general by date:

Previous
From: Aviel Buskila
Date:
Subject: Re: repmgr won't update witness after failover
Next
From: Martín Marqués
Date:
Subject: Re: Migrations