Can't find the right generated column syntax

From: Bzzzz <lazyvirus(at)gmx(dot)com>
To: pgsql-novice <pgsql-novice(at)postgresql(dot)org>
Subject: Can't find the right generated column syntax
Date: 2019-11-26 02:30:41
Message-ID: 20191126033041.3869adb5@msi.defcon1.lan
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Hi list,

I've got this table:
date_start timestamptz,
date_end temstamptz

and I'd like to auto-generate a 3rd column with a tstzrange:
date_start timestamptz,
date_end temstamptz,
duration tstzrange GENERATED ALWAYS AS ( ? ) STORED

but I can't find the right syntax to do so :/ (is it even possible ?)

Jean-Yves

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message David G. Johnston 2019-11-26 02:41:00 Re: Can't find the right generated column syntax
Previous Message Vianello, Dan A 2019-11-18 15:56:33 RE: Why oh why is this join not working?