mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-28 09:17:02 +08:00
Convert a few more datatype input functions to report errors softly.
Convert the remaining string-category input functions (bpcharin, varcharin, byteain) to the new style. Discussion: https://postgr.es/m/3038346.1671060258@sss.pgh.pa.us
This commit is contained in:
@ -72,6 +72,11 @@ INSERT INTO CHAR_TBL (f1) VALUES ('abcde');
|
||||
|
||||
SELECT * FROM CHAR_TBL;
|
||||
|
||||
-- Also try it with non-error-throwing API
|
||||
SELECT pg_input_is_valid('abcd ', 'char(4)');
|
||||
SELECT pg_input_is_valid('abcde', 'char(4)');
|
||||
SELECT pg_input_error_message('abcde', 'char(4)');
|
||||
|
||||
--
|
||||
-- Also test "char", which is an ad-hoc one-byte type. It can only
|
||||
-- really store ASCII characters, but we allow high-bit-set characters
|
||||
|
||||
Reference in New Issue
Block a user