Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1YB6Ou-0005rS-UZ for pgsql-bugs@arkaria.postgresql.org; Tue, 13 Jan 2015 18:41:13 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1YB6Ou-0005md-3G for pgsql-bugs@arkaria.postgresql.org; Tue, 13 Jan 2015 18:41:12 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1YB6Os-0005kT-Gs for pgsql-bugs@postgresql.org; Tue, 13 Jan 2015 18:41:10 +0000 Received: from mout.gmx.net ([212.227.15.19]) by magus.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1YB6Oo-0005Up-Hy for pgsql-bugs@postgresql.org; Tue, 13 Jan 2015 18:41:09 +0000 Received: from auth2-smtp.messagingengine.com ([66.111.4.228]) by mail.gmx.com (mrgmx002) with ESMTPSA (Nemesis) id 0MHHZT-1Xy9yt04wN-00E6Hp for ; Tue, 13 Jan 2015 19:41:04 +0100 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailauth.nyi.internal (Postfix) with ESMTP id 9F4B62108B for ; Tue, 13 Jan 2015 13:41:02 -0500 (EST) Received: from frontend1 ([10.202.2.160]) by compute1.internal (MEProxy); Tue, 13 Jan 2015 13:41:02 -0500 X-Sasl-enc: dcwNyxO5Egga/H5kDsbqJhQH+9+RaTYN8hQtX4IJokRT 1421174462 Received: from [192.168.1.70] (unknown [204.145.120.11]) by mail.messagingengine.com (Postfix) with ESMTPA id 58142C00014; Tue, 13 Jan 2015 13:41:02 -0500 (EST) Message-ID: <54B566BE.6030309@gmx.net> Date: Tue, 13 Jan 2015 13:41:02 -0500 From: Peter Eisentraut User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:31.0) Gecko/20100101 Thunderbird/31.3.0 MIME-Version: 1.0 To: ing.marco.colombo@gmail.com, pgsql-bugs@postgresql.org Subject: Re: BUG #12088: pg_upgrade 9.3 -> 9.4rc1 - implicit cast not ported References: <20141128082816.5720.15278@wrigleys.postgresql.org> In-Reply-To: <20141128082816.5720.15278@wrigleys.postgresql.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K0:nkTMKW9j1d2YnV5EOlE00B+pjTf534/DBWTlyDF/W+aayrCGW/E sGMpdimnEKTRJsDXAyMziStAh8QzDOrZtEzk8LvEWYqF+mFpKzF3KhBTGXlHYR5iBaXvnXd 17i9iHTnDFs+HcoSNoQvvpty/dRqoG403HkFszW8AB1qD7G8Fc04eNvVN16cuedUc+vwwp5 pLWMg2FacasGgObdHGl2A== X-UI-Out-Filterresults: notjunk:1; X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org On 11/28/14 3:28 AM, ing.marco.colombo@gmail.com wrote: > Hi, we have defined some implicit cast in the schema. After pg_upgrade > process, these have been dropped and we had to create them again. > > Cast are defined as: > > create cast (varchar as numeric) with inout as implicit; > > create cast (unknown as numeric) with inout as implicit; > > create cast (unknown as text) with inout as implicit; > > create cast (unknown as integer) with inout as implicit; pg_dump doesn't dump these casts. There is a source code comment that explains why: /* * As per discussion we dump casts if one or more of the underlying * objects (the conversion function and the two data types) are not * builtin AND if all of the non-builtin objects are included in the dump. * Builtin meaning, the namespace name does not start with "pg_". * * However, for a cast that belongs to an extension, we must not use this * heuristic, but just dump the cast iff we're told to (via dobj.dump). */ So recreating the casts manually after the upgrade is the best workaround at the moment. -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs