Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bJWH7-0008Sw-Ua for pgsql-hackers@arkaria.postgresql.org; Sun, 03 Jul 2016 01:32:46 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1bJWH7-0001Q6-BH for pgsql-hackers@arkaria.postgresql.org; Sun, 03 Jul 2016 01:32:45 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bJWH5-0001Px-Od for pgsql-hackers@postgresql.org; Sun, 03 Jul 2016 01:32:43 +0000 Received: from [2600:3c02::f03c:91ff:fe70:c491] (helo=apinaye.timbira.com.br) by makus.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bJWH2-0003KM-Ms for pgsql-hackers@postgresql.org; Sun, 03 Jul 2016 01:32:42 +0000 Received: by apinaye.timbira.com.br (Postfix, from userid 110) id 62B4C173E0D; Sat, 2 Jul 2016 22:32:39 -0300 (BRT) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on apinaye X-Spam-Level: X-Spam-Status: No, score=-100.2 required=5.0 tests=ALL_TRUSTED,BAYES_00, DNS_FROM_AHBL_RHSBL,URIBL_BLOCKED,USER_IN_WHITELIST autolearn=no version=3.3.1 Received: from [10.3.2.26] (unknown [181.222.168.152]) by apinaye.timbira.com.br (Postfix) with ESMTPSA id 74F32173E09; Sat, 2 Jul 2016 22:32:38 -0300 (BRT) Subject: Re: to_date_valid() To: Andreas 'ads' Scherbaum , PostgreSQL mailing lists References: <57786490.9010201@wars-nicht.de> From: Euler Taveira Organization: Timbira Message-ID: Date: Sat, 2 Jul 2016 22:32:36 -0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Icedove/45.1.0 MIME-Version: 1.0 In-Reply-To: <57786490.9010201@wars-nicht.de> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Host-Lookup-Failed: Reverse DNS lookup failed for 2600:3c02::f03c:91ff:fe70:c491 (failed) X-Pg-Spam-Score: -1.1 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org On 02-07-2016 22:04, Andreas 'ads' Scherbaum wrote: > The attached patch adds a new function "to_date_valid()" which will > validate the date and return an error if the input and output date do > not match. Tests included, documentation update as well. > Why don't you add a third parameter (say, validate = true | false) instead of creating another function? The new parameter could default to false to not break compatibility. -- Euler Taveira Timbira - http://www.timbira.com.br/ PostgreSQL: Consultoria, Desenvolvimento, Suporte 24x7 e Treinamento -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers