Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1t8RwR-004G4o-Ak for pgsql-general@arkaria.postgresql.org; Tue, 05 Nov 2024 22:22:26 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1t8RwN-000y3I-Mx for pgsql-general@arkaria.postgresql.org; Tue, 05 Nov 2024 22:22:24 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1t8RwN-000y3A-CJ for pgsql-general@lists.postgresql.org; Tue, 05 Nov 2024 22:22:23 +0000 Received: from smtp.burggraben.net ([2a01:4f8:140:510a::3]) by magus.postgresql.org with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1t8RwF-000Ouc-KA for pgsql-general@lists.postgresql.org; Tue, 05 Nov 2024 22:22:23 +0000 Received: from elch.exwg.net (elch.exwg.net [IPv6:2001:470:7120:1:21b:21ff:fef0:248b]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "elch.exwg.net", Issuer "R10" (verified OK)) by smtp.burggraben.net (Postfix) with ESMTPS id D6E02C01105; Tue, 5 Nov 2024 23:22:15 +0100 (CET) Received: by elch.exwg.net (Postfix, from userid 1000) id AE122EAC06; Tue, 05 Nov 2024 23:22:15 +0100 (CET) Date: Tue, 5 Nov 2024 23:22:15 +0100 From: Christoph Moench-Tegeder To: Matt Zagrabelny Cc: "pgsql-generallists.postgresql.org" Subject: Re: adsrc Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/2.2.13 (2024-03-09) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk ## Matt Zagrabelny (mzagrabe@d.umn.edu): > I'd like to upgrade the database to Pg 15, but when I connect and perform > some tasks in the app, I get: > > ERROR: column d.adsrc does not exist at character 331 That pg_attrdef.adsrc was already marked as "historical, and is best not used" in 9.4: https://www.postgresql.org/docs/9.4/catalog-pg-attrdef.html (In fact, that notice was added in 8.0). The official way to get the human-readable representation of the column's default value is "pg_get_expr(d.adbin, d.adrelid)" (use that instead of d.adsrc) - that way the fix is rather straight-forward. Documentation on pg_get_expr() is in this table: https://www.postgresql.org/docs/15/functions-info.html#FUNCTIONS-INFO-CATALOG-TABLE Regards, Christoph -- Spare Space