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 1w7fIO-005Zf3-0f for pgsql-hackers@arkaria.postgresql.org; Tue, 31 Mar 2026 20:02:40 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1w7fIM-00D55b-2V for pgsql-hackers@arkaria.postgresql.org; Tue, 31 Mar 2026 20:02:39 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1w7fIM-00D55T-1B for pgsql-hackers@lists.postgresql.org; Tue, 31 Mar 2026 20:02:38 +0000 Received: from mail-dl1-x122c.google.com ([2607:f8b0:4864:20::122c]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1w7fIL-000000021Vy-0V66 for pgsql-hackers@lists.postgresql.org; Tue, 31 Mar 2026 20:02:37 +0000 Received: by mail-dl1-x122c.google.com with SMTP id a92af1059eb24-12a747e7b2fso3043828c88.0 for ; Tue, 31 Mar 2026 13:02:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1774987356; cv=none; d=google.com; s=arc-20240605; b=DBwyGKDh8cD3eFppgKvTYCZVKsN3UZqs0gkpBHLIDF8XSim5wSRLl+ZeH35kM9uuPb 0zbHHTnil+InqUHNfLd3PVpx6LKghxWvY5OL4u608N1QcT3A3uNXz67NgxD9CvC4hbBc dF5ROCYHV/boFf0GnfjMvzyPwVQSxCoKX5kUPm8TXQ3B3lotQ7qbFNHCsOGxvNpDKo/H Yqd3yfqbnaOgQXWzJtnYJCJa2MpvLXq6HagutWf67z//2EJ/3MmDiO/YNqn3u5hm5ttT HviMHJWoUlPPeaBDRct6a2IpqbS76JTe1UkTX0FWHw+ktA6QmDtmevCF3Ff5VCVwY260 8+Og== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=gKoNgTkECqSJbouxwX/102SBJD+veWTUhphWyOJ3RhI=; fh=mrImEWWopS9tZqSE6cGN2YC7LEr37a+RIFN0jGKChpc=; b=KOwTl8vl720KyB01uxtPVFsxrr1mr63rYBSOX/H5jcmz/eGu0T4IwnnX0YZaPdcTbu 9tr1eDyqht+YacbD8GZZiLKuZnxiKIHdSgUZ2pm5jzm69KbX2dVQqnhGf0fJ1yy9ogql XCp3Wm2XqtQLpggI4UjfQcgxdwxgl3Is3DPtHpqIR+Q0fReOBclgoOy9MTMCqUB5Lxl7 WHDPvnFFovcVpCJWcgKipoZG8RJuuJz5ptPwwZtLCeryt9hqixr01uirKDW4UggO+m/V xFT9uH1O+G1aYyJ529TvjgQPh630pJdZWi4g8z60X6eyhu93mkx6BBh6HP5bz3l8v6C6 R9QA==; darn=lists.postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1774987356; x=1775592156; darn=lists.postgresql.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=gKoNgTkECqSJbouxwX/102SBJD+veWTUhphWyOJ3RhI=; b=SYOBqhi0l9i3XP6OGbo5IQDz2PtG8VZcMI6wkIkswhgs4GKhyFLwJuk1zIaThAjJQF u15nePXHkCSos+b0JBI/aweamwE6Mb7lKKyopalm6RaqSOTqP25pQRBkcVoayehMtEmq qD2wbL/q2Au3t5D/EQElG51z0tf3WSY5Px8P6FnD6w+JEaDfpRaKPDWAB+MDhA3ulSWp +kQvqA67kNnLcckPfcSc0Ic/lJ13bNwvCTyPvGgDNn/7D4zikZd5KfL8EIFtrCG3shdB HMxekMdYwuLMzBdCmFP1KtqI6pdD/vks8cZFBTP3MnHx2R856YMOyAiypJYK7Hu1mwTE Ca+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1774987356; x=1775592156; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=gKoNgTkECqSJbouxwX/102SBJD+veWTUhphWyOJ3RhI=; b=sR1jLHiL1W/Is2LvnB+18HUpLx9C5J2ecUXrUBEBwteuQ+F4onpMcRaYiYSAxYBclA YQfdUNvncmNCXii3JbtyTYZOC7sZbXmpUo/iifgubArI1NKLU4GTCVsLpgoyn/rF3Q2G sy2hYbdfh4veaJHkh19YEm5y7etPzKB0boK04kAT/pWhX0rcufAqCCMafKZAEglrBRZK +hzKtTbANx065VDDruzGUVr93prtTUTxK2GhPCxXS/EO4lVVTF1PWrB4MPZa8Vc6WLL9 Jsw1vBB1hK+1PQ4F7QZxswEbd3Fa+9IhC2kIJZAQhwPBqeqyhuvxC1mzr4zNDW+gKsvI HDnQ== X-Forwarded-Encrypted: i=1; AJvYcCUQTrxM3tXDTdmgoWsfmhQ1T2m17J+Nd/iiMr80rLBTj407hueiQh26CMX1OTWCI7oadHvQWsccxWNxFn53@lists.postgresql.org X-Gm-Message-State: AOJu0YyI+DN93ukRtMUdbPmuwZzpBLKuoxrwEbe0Qn1YHQUj90YuF3H/ GtPuIEGwXS6SxE8hB4mz10KWRb7Cl42kcVGwc+lMbT5tWiHj2adO3ei6d/DKRU8fH44QH8dq1lW bmwNeok3CXxqy2jRyE6n4fAtR7/yyH2I= X-Gm-Gg: ATEYQzzuf0sks8drsc/g4gOBbySvq/pYB80B4dsnsLc+2TBrXBKNqr0v1SHQ0lDmDae GQo/AJvgkFSrNhGB9cFA0usyiByFCUzDSFQq4OoMMtD1m9P+CKKODlE0q5ru0ZLCvdiuO0Gi4ry cWCVxgG4shzOmK4rICAn0NqHt/deybI9MTx7h2yu7K3CZwdGFJcg8dGPDTcANUEUaKyKI7Blx5f 5JKHFoqN3SRcr28gptPG12Db98Lhwooe/cBcTcjM/MQfQAQJxwDxcrJCsbRNurbTycmpVdo/DeD L4XPGaahjCv3UjjYO7iotYWSj+xKDChx7pa/UcDllYbSz5G4a+P6mFLB0CmtM3/gcRPJE0sYrSt ymgs2k8pAEwyJcNKPuV8alPXF X-Received: by 2002:a05:701a:c94f:b0:119:e56c:18b1 with SMTP id a92af1059eb24-12be6557327mr437717c88.25.1774987356070; Tue, 31 Mar 2026 13:02:36 -0700 (PDT) MIME-Version: 1.0 References: <5ae9578e-f25e-49c5-97ab-ad27bc2050b5@eisentraut.org> <5221f892-e1d5-4943-a3dc-5c9c7bdf4924@eisentraut.org> In-Reply-To: From: Corey Huinker Date: Tue, 31 Mar 2026 16:02:22 -0400 X-Gm-Features: AQROBzAzpndGriXASUo6InvEqyVOsREiNuplYUYMMP8NeO6Fw4fDptIwz6e1eL4 Message-ID: Subject: Re: CAST(... ON DEFAULT) - WIP build on top of Error-Safe User Functions To: jian he Cc: Amul Sul , Peter Eisentraut , Kirill Reshke , Vik Fearing , Isaac Morland , pgsql-hackers@lists.postgresql.org Content-Type: multipart/alternative; boundary="000000000000d6e66e064e5772af" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --000000000000d6e66e064e5772af Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, Mar 31, 2026 at 10:48=E2=80=AFAM jian he wrote: > Hi. > I've incorporated the changes you sent me off-list. > The attached v1 no-cfbot is your proposed change. > I also did some minor comments adjustments. > The remaining patches continue to work for me. I hope we can get all of this into 19, but if we can't I think it would be ok to limit src/dest type combinations to those that can be handled by CoerceViaIO, at least for 19. I think the vast majority of the usage of this function will be mass ETLs where data is first loaded into a table of all text. --000000000000d6e66e064e5772af Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Tue, Mar 31,= 2026 at 10:48=E2=80=AFAM jian he <jian.universality@gmail.com> wrote:
Hi.
I've incorporated the changes you sent me off-list.
The attached v1 no-cfbot is your proposed change.
I also did some minor comments adjustments.

=
The remaining patches continue to work for me. I hope we can get all o= f this into 19, but if we can't I think it would be ok to limit src/des= t type combinations to those that can be handled by CoerceViaIO, at least f= or 19. I think the vast majority of the usage of this function will be mass= ETLs where data is first loaded into a table of all text.
=C2=A0=
--000000000000d6e66e064e5772af--