pg.ddx.io  pgsql-docs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Bruce Momjian <bruce@momjian.us>
To: ehansmair@prompt-software.de
To: pgsql-docs@lists.postgresql.org
Subject: Re: Documentation  9.8. Data Type Formatting Functions:  missing behaviour on invalid input at to_date()
Date: Fri, 12 Jun 2020 17:28:19 -0400
Message-ID: <20200612212819.GA6813@momjian.us> (raw)
In-Reply-To: <159135581922.7031.8149548798892105892@wrigleys.postgresql.org>
References: <159135581922.7031.8149548798892105892@wrigleys.postgresql.org>

On Fri, Jun  5, 2020 at 11:16:59AM +0000, PG Doc comments form wrote:
> The following documentation comment has been logged on the website:
> 
> Page: https://www.postgresql.org/docs/12/functions-formatting.html
> Description:
> 
> For the formatting functions, which convert between a string and a type like
> date, timestamp or number, there should be a description about the behaviour
> of i.e. to_date(input, mask) in case of invalid, not convertable input.
> 
> I expected a return value of NULL and got a execution error.

Well, the value isn't "unknown", it is invalid, so an error seems
appropriate.  I don't remember anyone complaining the expected a NULL
return.

-- 
  Bruce Momjian  <bruce@momjian.us>        https://momjian.us
  EnterpriseDB                             https://enterprisedb.com

  The usefulness of a cup is in its emptiness, Bruce Lee






view thread (4+ messages)  latest in thread

Message-ID: <20200612212819.GA6813@momjian.us>
Permalink:  ../20200612212819.GA6813@momjian.us/
Also on:    postgresql.org/message-id/20200612212819.GA6813@momjian.us

 · 

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-docs@postgresql.org
  Cc: bruce@momjian.us, ehansmair@prompt-software.de, pgsql-docs@lists.postgresql.org
  Subject: Re: Documentation  9.8. Data Type Formatting Functions:  missing behaviour on invalid input at to_date()
  In-Reply-To: <20200612212819.GA6813@momjian.us>

* 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