Re: Is it possible to use keywords (date units) in a function definition? - Mailing list pgsql-general

From David G. Johnston
Subject Re: Is it possible to use keywords (date units) in a function definition?
Date
Msg-id CAKFQuwYwjDZLTY1JkkTL-4VtmBdK23-FZzVs7woweP0h+FSDmQ@mail.gmail.com
Whole thread Raw
In response to Is it possible to use keywords (date units) in a function definition?  (Alistair Johnson <aewj@mit.edu>)
Responses Re: Is it possible to use keywords (date units) in a functiondefinition?  (Adrian Klaver <adrian.klaver@aklaver.com>)
List pgsql-general
On Mon, Jun 8, 2020 at 2:57 PM Alistair Johnson <aewj@mit.edu> wrote:

RETURN EXTRACT(datepart FROM end - start);
Any ideas? Is this even possible?

Use the "date_part" function.

David J.

pgsql-general by date:

Previous
From: David Rowley
Date:
Subject: Re: When to use PARTITION BY HASH?
Next
From: Ron
Date:
Subject: Re: Concurrenctly running CREATE TEMP TABLE IF NOT EXISTS [...] AS[...]