From: mail@eaden.net
To: pgsql-bugs@postgresql.org
Subject: BUG #13919: Cast error when table is empty.
Date: Fri, 05 Feb 2016 11:35:28 +0000
Message-ID: <20160205113528.2660.62254@wrigleys.postgresql.org> (raw)
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
The following bug has been logged on the website:
Bug reference: 13919
Logged by: Eaden McKee
Email address: mail@eaden.net
PostgreSQL version: 9.4.1
Operating system: Any
Description:
When trying to change the type of column I received the error :
PG::DatatypeMismatch: ERROR: column "date_of_birth" cannot be cast
automatically to type date
HINT: Specify a USING expression to perform the conversion.
I totally understand the error. However, there are no rows in the table, so
it IS possible to automatically to cast 0 strings into 0 dates.
If there are no rows, can the column type just be changed?
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: mail@eaden.net
Subject: Re: BUG #13919: Cast error when table is empty.
In-Reply-To: <20160205113528.2660.62254@wrigleys.postgresql.org>
References: <20160205113528.2660.62254@wrigleys.postgresql.org>
* 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