'123':5 '456':7 'aaa':1 'bbb':3
(1 row)
--- ts_vector corner cases
+-- to_tsvector corner cases
select to_tsvector('""'::json);
to_tsvector
-------------
'123':5 '456':7 'aaa':1 'bbb':3
(1 row)
--- ts_vector corner cases
+-- to_tsvector corner cases
select to_tsvector('""'::jsonb);
to_tsvector
-------------
select json_to_tsvector('english', '{"a": "aaa in bbb", "b": 123, "c": 456, "d": true, "f": false, "g": null}'::json, '"boolean"');
select json_to_tsvector('english', '{"a": "aaa in bbb", "b": 123, "c": 456, "d": true, "f": false, "g": null}'::json, '["string", "numeric"]');
--- ts_vector corner cases
+-- to_tsvector corner cases
select to_tsvector('""'::json);
select to_tsvector('{}'::json);
select to_tsvector('[]'::json);
select jsonb_to_tsvector('english', '{"a": "aaa in bbb", "b": 123, "c": 456, "d": true, "f": false, "g": null}'::jsonb, '"boolean"');
select jsonb_to_tsvector('english', '{"a": "aaa in bbb", "b": 123, "c": 456, "d": true, "f": false, "g": null}'::jsonb, '["string", "numeric"]');
--- ts_vector corner cases
+-- to_tsvector corner cases
select to_tsvector('""'::jsonb);
select to_tsvector('{}'::jsonb);
select to_tsvector('[]'::jsonb);