pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Gary Stainburn <gary.stainburn@ringways.co.uk>
To: pgsql-sql@postgresql.org
Subject: Re: generated dates from record dates - suggestions
Date: Tue, 21 Aug 2012 11:31:49 +0100
Message-ID: <201208211131.49999.gary.stainburn@ringways.co.uk> (raw)
In-Reply-To: <CALBtUW6V8KW=N97XSjqRmDwGv-UP_LW6HYpor0u5qzZAhSu6gg@mail.gmail.com>
References: <201208201317.46588.gary.stainburn@ringways.co.uk>
	<CALBtUW6V8KW=N97XSjqRmDwGv-UP_LW6HYpor0u5qzZAhSu6gg@mail.gmail.com>

On Tuesday 21 August 2012 02:01:55 Johnny Winn wrote:
> I would define a function and use it to abstract the expected behavior. It
> would appear that there are several conditions so this abstraction would
> provide for both usability and maintainability.
>
> - Johnny

Johnny,

This was what I was wondering, and was looking for suggestions / best 
practices on how to do this.

I had first thought of embedding case/when statements in the view but it could 
easily become unweildy

-- 
Gary Stainburn
Group I.T. Manager
Ringways Garages
http://www.ringways.co.uk 




view thread (6+ messages)  latest in thread

Message-ID: <201208211131.49999.gary.stainburn@ringways.co.uk>
Permalink:  ../201208211131.49999.gary.stainburn@ringways.co.uk/
Also on:    postgresql.org/message-id/201208211131.49999.gary.stainburn@ringways.co.uk

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: gary.stainburn@ringways.co.uk
  Subject: Re: generated dates from record dates - suggestions
  In-Reply-To: <201208211131.49999.gary.stainburn@ringways.co.uk>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox