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.96) (envelope-from ) id 1vqzEk-004YQJ-0f for pgsql-bugs@arkaria.postgresql.org; Fri, 13 Feb 2026 19:53:58 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vqzEi-00G0EA-0m for pgsql-bugs@arkaria.postgresql.org; Fri, 13 Feb 2026 19:53:56 +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.96) (envelope-from ) id 1vqzCy-00G0Cc-0D for pgsql-bugs@lists.postgresql.org; Fri, 13 Feb 2026 19:52:08 +0000 Received: from mahout.postgresql.org ([2001:4800:3e1:1::227]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1vqzCv-00000000Xb5-2irE for pgsql-bugs@lists.postgresql.org; Fri, 13 Feb 2026 19:52:07 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=postgresql.org; s=20171124; h=Message-ID:Date:Reply-To:Cc:From:To:Subject: Content-Transfer-Encoding:MIME-Version:Content-Type:Sender:Content-ID: Content-Description:In-Reply-To:References; bh=ewlQQSi9mwGwYfukMIEyPIDOrwLI960d6ou5LtGmIRQ=; b=r1Vgkqvk1XgcN1Fu6bqg3F23H5 rRmcFiFxMw+l9ity1Vx8fy+JDA5MZpBQWJoHLS0GunS1bYfiu4akeCEo0LF6YKIvMGlfMdPW/Cy1p x/IODSJo98GwCyYL620/4FGhRxfODeV/DzarBJgH9yoOnWy7u8qKh2avk3VH8oI3ErwwlOx0ITRrv +aoqyZpYrIWm+13KjDWrng+DjIHMeQ9tz68Sllrr5dfGhgG/qjLD47LbbIUk9L/BB3Zmtr8vaC4DL VY9hMWL/JXk6qbrzzLr93vVXDyWOeVSaJWD+sJK0V4Dz+A+PCqQvBUfIu2b1z+tYf7v0jaBlOKtBF O8fOAzMQ==; Received: from wrigleys.postgresql.org ([2a02:16a8:dc51::60]) by mahout.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vqzCu-001cks-0o for pgsql-bugs@lists.postgresql.org; Fri, 13 Feb 2026 19:52:04 +0000 Received: from localhost ([127.0.0.1] helo=wrigleys.postgresql.org) by wrigleys.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vqzCr-003IZ1-2f for pgsql-bugs@lists.postgresql.org; Fri, 13 Feb 2026 19:52:02 +0000 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Subject: BUG #19409: Function jsonb_strip_nulls() changed from immutable to stable. To: pgsql-bugs@lists.postgresql.org From: PG Bug reporting form Cc: lucio.chiessi@trustly.com Reply-To: lucio.chiessi@trustly.com, pgsql-bugs@lists.postgresql.org Date: Fri, 13 Feb 2026 19:51:03 +0000 Message-ID: <19409-e16cd2605e59a4af@postgresql.org> X-Auto-Response-Suppress: All Auto-Submitted: auto-generated List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk The following bug has been logged on the website: Bug reference: 19409 Logged by: Lucio Chiessi Email address: lucio.chiessi@trustly.com PostgreSQL version: 18.1 Operating system: MacOS 15.7.3 Description: =20 Hello. We are using, in PostgreSQL 16, the function jsonb_strip_nulls(jsonb) in a calculated table column, as shown below: attributes_hash text generated always as (md5(jsonb_strip_nulls(attributes)::text)) stored, But using PostgreSQL 18 we having this error: [ERROR] SQL State : 42P17 [ERROR] Error Code : 0 [ERROR] Message : ERROR: generation expression is not immutable But this fails in PostgreSQL 18, because the jsonb_strip_nulls ( target jsonb [,strip_in_arrays boolean ] ) function changed from immutable to stable. In PostgreSQL. I used the query below in both versions, with this change: select proname,provolatile,pronargs,proparallel,proargnames from pg_proc where proname in ('jsonb_strip_nulls') and prokind =3D 'f'; In PostgreSQL 16.6, we have the value of 'provolatile' column as 'i', and in PostgreSQL 18.1 as 's'. I can't find any information about this change in the Release Notes v18. Can we consider this a bug, or is this a normal behavior introduced in v18? Thanks a lot.