pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Kyle <kyle@ccidomain.com>
To: Forum - PostGreSQL General <pgsql-general@postgresql.org>
Subject: Re: [SQL] Best way to delete time stamped data?
Date: Sun, 04 May 2003 09:09:05 -0400
Message-ID: <3EB510F1.8090708@ccidomain.com> (raw)
References: <3EB2EBF0.8010003@ccidomain.com>
	<200305021619.41879.josh@agliodbs.com>

Josh,

Thanks, even my boss can read the new statement:

DELETE FROM ONLY richtable WHERE age(trxdate) > '90 days';

Your disparaging aside, that is exactly the kind of expression 
compaction I was after!  :)

And yeah, I have a deep PERL background, but that's not a bad thing.

-Kyle

Josh Berkus wrote:
> More compact than that ?!?!?!  
> Maybe you should go into Perl, instead of SQL -- I think the one-liners would 
> suit you.
> 
> You can use the age() function, but all that funciton does is the same 
> calculation you have above.




view thread (8+ messages)  latest in thread

Message-ID: <3EB510F1.8090708@ccidomain.com>
Permalink:  ../3EB510F1.8090708@ccidomain.com/
Also on:    postgresql.org/message-id/3EB510F1.8090708@ccidomain.com

 · 

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: kyle@ccidomain.com, pgsql-general@postgresql.org
  Subject: Re: [SQL] Best way to delete time stamped data?
  In-Reply-To: <3EB510F1.8090708@ccidomain.com>

* 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