spg-engine 7.39.10

Execution engine for SPG: glues spg-sql parsing to spg-storage. Foreign keys, joins, vectors, cold tier.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
//! v7.39.2 — the argument counts each built-in REFUSES, as data.
//!
//! v7.39.3 — regenerated after the sweep that gave the remaining
//! families PostgreSQL's sentence, and after the generator's own name
//! scraper was widened. It had read three source files and only arms
//! that ENDED in `=>`, so a one-line arm — most of them — was invisible:
//! 86 names were missing, `host` and `encode` and `ltrim` among them.
//! The consequence was a wrong SENTENCE rather than a missing check.
//! A name outside this table is never refused BEFORE the scan, so it
//! falls through to row time, where a bare literal has already become
//! `text`: `SELECT host('a','b')` read `host(text, text)` where
//! PostgreSQL 18.6 says `host(unknown, unknown)`.
//!
//! The widening went wrong in BOTH directions on the way in, and the
//! workspace suite caught each one. `json_insert` and `json_set` are
//! routed by the VALUE of their second argument, so probing with NULLs
//! never reached MySQL's implementation and five arguments — ordinary
//! MySQL — came back refused. Requiring every filling to refuse then
//! went too far the other way: `ltrim(1,1,1)` is stopped by the type
//! guard ahead of the dispatch, which answers a type error rather than
//! `WrongArity`, so a real arity refusal read as acceptance. The rule
//! is what each answer is EVIDENCE of: a count any filling RUNS is
//! accepted, a count no filling runs and some filling calls
//! `WrongArity` is refused, and anything else says nothing.
//!
//! The wrong-arity check lives inside the row-time dispatch, so a query
//! over an EMPTY table never reaches it: `SELECT lower(t, n) FROM t`
//! answered zero rows and no error while `t` was empty, and raised the
//! moment it had one row — the same shape as the unknown-column defect
//! closed earlier in this release, in a different place.
//!
//! Refusing before the scan needs the accepted counts as data, and two
//! ways of deriving them were tried and refuted first: `PG_PROC_FUNCS`
//! does not describe SPG's overloads (dozens of legitimate calls came
//! back refused), and the catalog's volatility column omits `nextval`
//! and `setval`, so probing a call at plan time could advance a
//! sequence — changing data to improve a message.
//!
//! This table is derived by asking the DISPATCH ITSELF, offline: call
//! each name with N NULL arguments and record only the counts it
//! answers `WrongArity` to. Anything else — a value error, a type
//! refusal, success — counts as ACCEPTED, so a function whose guard is
//! not arity-first, and a variadic one that never raises `WrongArity`
//! at all, are both recorded as accepting everything.
//!
//! Both dialects have to refuse a count for it to be recorded. The
//! first version probed one, and the table was consulted in both, so a
//! count only the MySQL grammar accepts came back refused:
//! `JSON_OBJECT('k', 1, 'v', 2)` — an ordinary variadic call — was
//! rejected before the scan. That is exactly the over-refusal this
//! table is supposed to be incapable of, and the claim was false until
//! the probe asked both.
//!
//! With that, the table can UNDER-refuse but not OVER-refuse. That
//! asymmetry is what makes it safe to consult before a scan, and it is
//! what the two refuted approaches could not promise.
//!
//! Generated, and checked: `arity_table_is_current` in
//! `eval/functions.rs` re-derives it and fails on any difference, so a
//! dispatch that changes its arity without regenerating this file is a
//! red test rather than a silent divergence.
//!
//! Regenerate with:
//!   cargo test -p spg-engine --lib arity_table_generator -- --ignored --nocapture

/// `(name, refused argument counts)`, sorted by name. A name absent
/// here is not judged.
pub(crate) static REFUSED_ARITIES: &[(&str, &[usize])] = &[
    ("__array_assign", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("__array_assign_slice", &[0, 1, 2, 3, 5, 6, 7, 8]),
    ("_pg_char_max_length", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("_pg_char_octet_length", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("_pg_datetime_precision", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("_pg_numeric_precision", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("_pg_numeric_scale", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("abs", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("acldefault", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("acos", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("acosd", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("acosh", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("adddate", &[0]),
    ("addtime", &[0]),
    ("age", &[0, 3, 4, 5, 6, 7, 8]),
    ("armor", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("array_append", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("array_cat", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("array_dims", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("array_fill", &[0, 1, 4, 5, 6, 7, 8]),
    ("array_length", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("array_lower", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("array_ndims", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("array_position", &[0, 1, 4, 5, 6, 7, 8]),
    ("array_positions", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("array_prepend", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("array_remove", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("array_replace", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("array_reverse", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("array_sample", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("array_shuffle", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("array_sort", &[0, 4, 5, 6, 7, 8]),
    ("array_to_json", &[0, 3, 4, 5, 6, 7, 8]),
    ("array_to_string", &[0, 1, 4, 5, 6, 7, 8]),
    ("array_to_tsvector", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("array_upper", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("ascii", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("asin", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("asind", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("asinh", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("atan", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("atan2", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("atan2d", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("atand", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("atanh", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("bin", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("bit_count", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("bit_length", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("broadcast", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("bt_index_check", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("btrim", &[0, 3, 4, 5, 6, 7, 8]),
    ("bytea_and", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("bytea_or", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("bytea_xor", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("byteacat", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("byteaxor", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("cardinality", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("casefold", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("cash_words", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("cashlarger", &[0]),
    ("cashsmaller", &[0]),
    ("cbrt", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("ceil", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("ceiling", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("char_length", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("character_length", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("chr", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("conv", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("convert", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("convert_from", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("convert_to", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("convert_tz", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("cos", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("cosd", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("cosh", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("cot", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("cotd", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("crc32", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("crc32c", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("crypt", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("current_setting", &[0, 3, 4, 5, 6, 7, 8]),
    ("currval", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("date_add", &[0]),
    ("date_bin", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("date_format", &[0]),
    ("date_part", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("date_sub", &[0]),
    ("date_subtract", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("date_trunc", &[0, 1, 4, 5, 6, 7, 8]),
    ("datediff", &[0]),
    ("daterange", &[0, 1, 4, 5, 6, 7, 8]),
    ("day", &[0]),
    ("dayname", &[0]),
    ("dayofmonth", &[0]),
    ("dayofweek", &[0]),
    ("dayofyear", &[0]),
    ("dearmor", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("decode", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("degrees", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("difference", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("digest", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("div", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("elt", &[0, 1]),
    ("encode", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("ends_with", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("erf", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("erfc", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("error_on_null", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("exp", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("export_set", &[0, 1, 2, 6, 7, 8]),
    ("factorial", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("family", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("field", &[0, 1]),
    ("find_in_set", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("floor", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("from_base64", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("from_days", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("from_unixtime", &[0, 3, 4, 5, 6, 7, 8]),
    ("gcd", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("gen_random_bytes", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("gen_random_uuid", &[1, 2, 3, 4, 5, 6, 7, 8]),
    ("gen_salt", &[0, 3, 4, 5, 6, 7, 8]),
    ("gen_uuid_v7", &[2, 3, 4, 5, 6, 7, 8]),
    ("generate_subscripts", &[0, 1, 4, 5, 6, 7, 8]),
    ("get_bit", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("get_byte", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("get_format", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("has_table_privilege", &[0, 1, 4, 5, 6, 7, 8]),
    ("hashbytea", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("hashint2", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("hashint4", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("hashint8", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("hashtext", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("hex", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("hmac", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("host", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("hostmask", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("hour", &[0]),
    ("if", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("ifnull", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("inet6_aton", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("inet6_ntoa", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("inet_aton", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("inet_merge", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("inet_ntoa", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("inet_same_family", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("initcap", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("insert", &[0, 1, 2, 3, 5, 6, 7, 8]),
    ("instr", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("int4range", &[0, 1, 4, 5, 6, 7, 8]),
    ("int8range", &[0, 1, 4, 5, 6, 7, 8]),
    ("is_ipv4", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("is_ipv6", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("is_normalized", &[0, 3, 4, 5, 6, 7, 8]),
    ("is_uuid", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("isempty", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("isfinite", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_array_append", &[0, 1, 2, 4, 6, 8]),
    ("json_array_elements_text", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_array_insert", &[0, 1, 2, 4, 6, 8]),
    ("json_array_length", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_concat", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("json_contains", &[0, 1, 4, 5, 6, 7, 8]),
    ("json_contains_path", &[0, 1, 2]),
    ("json_delete", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("json_delete_path", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("json_depth", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_extract", &[0, 1]),
    ("json_insert", &[0, 1, 2, 6, 8]),
    ("json_keys", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_length", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_merge", &[0, 1]),
    ("json_merge_patch", &[0, 1]),
    ("json_merge_preserve", &[0, 1]),
    ("json_object_keys", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_overlaps", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("json_path_exists", &[0, 1]),
    ("json_path_match", &[0, 1]),
    ("json_path_query", &[0, 1, 5, 6, 7, 8]),
    ("json_path_query_array", &[0, 1, 5, 6, 7, 8]),
    ("json_path_query_first", &[0, 1, 5, 6, 7, 8]),
    ("json_pretty", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_quote", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_remove", &[0, 1]),
    ("json_replace", &[0, 1, 2, 4, 6, 8]),
    ("json_scalar", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_search", &[0, 1, 2]),
    ("json_serialize", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_set", &[0, 1, 2, 6, 8]),
    ("json_storage_size", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_strip_nulls", &[0, 3, 4, 5, 6, 7, 8]),
    ("json_to_tsvector", &[0, 1, 4, 5, 6, 7, 8]),
    ("json_type", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_typeof", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_unquote", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_valid", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("json_value", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("jsonb_array_element_text", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("jsonb_array_length", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("jsonb_concat", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("jsonb_contained", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("jsonb_contains", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("jsonb_delete", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("jsonb_delete_path", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("jsonb_exists", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("jsonb_exists_all", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("jsonb_exists_any", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("jsonb_extract_path_text", &[0, 1]),
    ("jsonb_insert", &[0, 1, 2, 6, 8]),
    ("jsonb_object", &[0, 3, 4, 5, 6, 7, 8]),
    ("jsonb_object_keys", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("jsonb_path_exists", &[0, 1]),
    ("jsonb_path_match", &[0, 1]),
    ("jsonb_path_query", &[0, 1, 5, 6, 7, 8]),
    ("jsonb_path_query_array", &[0, 1, 5, 6, 7, 8]),
    ("jsonb_path_query_first", &[0, 1, 5, 6, 7, 8]),
    ("jsonb_pretty", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("jsonb_set", &[0, 1, 2, 6, 8]),
    ("jsonb_set_lax", &[0, 1, 2, 6, 7, 8]),
    ("jsonb_strip_nulls", &[0, 3, 4, 5, 6, 7, 8]),
    ("jsonb_to_tsvector", &[0, 1, 4, 5, 6, 7, 8]),
    ("jsonb_typeof", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("justify_days", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("justify_hours", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("justify_interval", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("last_day", &[0]),
    ("lcase", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("lcm", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("left", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("length", &[0, 3, 4, 5, 6, 7, 8]),
    ("levenshtein", &[0, 1, 6, 7, 8]),
    ("levenshtein_less_equal", &[0, 1, 6, 7, 8]),
    ("like_escape", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("ln", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("locate", &[0, 1, 4, 5, 6, 7, 8]),
    ("log", &[0, 3, 4, 5, 6, 7, 8]),
    ("log10", &[0, 3, 4, 5, 6, 7, 8]),
    ("log2", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("lower", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("lower_inc", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("lower_inf", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("lpad", &[0, 1, 4, 5, 6, 7, 8]),
    ("ltrim", &[0, 3, 4, 5, 6, 7, 8]),
    ("macaddr8_set7bit", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("make_date", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("make_interval", &[8]),
    ("make_set", &[0, 1]),
    ("make_time", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("make_timestamp", &[0, 1, 2, 3, 4, 5, 7, 8]),
    ("make_timestamptz", &[0, 1, 2, 3, 4, 5, 8]),
    ("makeaclitem", &[0, 1, 2, 3, 5, 6, 7, 8]),
    ("makedate", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("maketime", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("masklen", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("md5", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("microsecond", &[0]),
    ("mid", &[0, 1, 4, 5, 6, 7, 8]),
    ("min_scale", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("minute", &[0]),
    ("mod", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("month", &[0]),
    ("monthname", &[0]),
    ("name_const", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("netmask", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("network", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("nextval", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("normalize", &[0, 3, 4, 5, 6, 7, 8]),
    ("nullif", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("numnode", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("numrange", &[0, 1, 4, 5, 6, 7, 8]),
    ("oct", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("octet_length", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("ord", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("overlay", &[0, 1, 2, 5, 6, 7, 8]),
    ("parse_ident", &[0, 3, 4, 5, 6, 7, 8]),
    ("period_add", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("period_diff", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("pg_basetype", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_bytes_pretty", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_collation_for", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_column_compression", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_column_size", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_encoding_max_length", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_get_serial_sequence", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("pg_input_is_valid", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("pg_is_json", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("pg_lsn_hash", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_lsn_larger", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("pg_lsn_smaller", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("pg_partition_ancestors", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_partition_root", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_size_bytes", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_size_pretty", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_typeof", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("pg_wal_lsn_diff", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("pg_xact_status", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("phraseto_tsquery", &[0, 3, 4, 5, 6, 7, 8]),
    ("pi", &[1, 2, 3, 4, 5, 6, 7, 8]),
    ("plainto_tsquery", &[0, 3, 4, 5, 6, 7, 8]),
    ("point", &[0, 3, 4, 5, 6, 7, 8]),
    ("position", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("pow", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("power", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("quarter", &[0]),
    ("querytree", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("quote", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("radians", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("random", &[1, 3, 4, 5, 6, 7, 8]),
    ("random_bytes", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("random_int", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("random_normal", &[3, 4, 5, 6, 7, 8]),
    ("range_adjacent", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("range_merge", &[0, 3, 4, 5, 6, 7, 8]),
    ("regexp_count", &[0, 1, 5, 6, 7, 8]),
    ("regexp_instr", &[0, 1, 8]),
    ("regexp_like", &[0, 1, 4, 5, 6, 7, 8]),
    ("regexp_match", &[0, 1, 4, 5, 6, 7, 8]),
    ("regexp_matches", &[0, 1, 4, 5, 6, 7, 8]),
    ("regexp_replace", &[0, 1, 2, 7, 8]),
    ("regexp_split_to_array", &[0, 1, 4, 5, 6, 7, 8]),
    ("regexp_substr", &[0, 1, 6, 7, 8]),
    ("regproc_to_text", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("regprocedure_to_text", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("repeat", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("replace", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("reverse", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("right", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("round", &[0, 3, 4, 5, 6, 7, 8]),
    ("row_to_json", &[0, 3, 4, 5, 6, 7, 8]),
    ("row_to_jsonb", &[0, 3, 4, 5, 6, 7, 8]),
    ("rpad", &[0, 1, 4, 5, 6, 7, 8]),
    ("rtrim", &[0, 3, 4, 5, 6, 7, 8]),
    ("scale", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("sec_to_time", &[0]),
    ("second", &[0]),
    ("set_bit", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("set_byte", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("setseed", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("setval", &[0, 1, 4, 5, 6, 7, 8]),
    ("setweight", &[0, 1, 4, 5, 6, 7, 8]),
    ("sha", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("sha1", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("sha2", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("sha224", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("sha256", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("sha384", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("sha512", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("show_trgm", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("sign", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("similar_escape", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("similar_to_escape", &[0, 3, 4, 5, 6, 7, 8]),
    ("similarity", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("sin", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("sind", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("sinh", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("soundex", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("spg_bt_index_check", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("spg_verify_heapam", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("split_part", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("sqrt", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("starts_with", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("str_to_date", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("strcmp", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("string_to_array", &[0, 1, 4, 5, 6, 7, 8]),
    ("strip", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("strpos", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("subdate", &[0]),
    ("substr", &[0, 1, 4, 5, 6, 7, 8]),
    ("substring", &[0, 1, 4, 5, 6, 7, 8]),
    ("substring_index", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("subtime", &[0]),
    ("tan", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("tand", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("tanh", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("text_ge", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("text_gt", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("text_le", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("text_lt", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("text_starts_with", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("textcat", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("texteq", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("textne", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("time_format", &[0]),
    ("time_to_sec", &[0]),
    ("timediff", &[0]),
    ("timeofday", &[1, 2, 3, 4, 5, 6, 7, 8]),
    ("timestampadd", &[0, 1, 2]),
    ("timestampdiff", &[0, 1]),
    ("timezone", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("to_ascii", &[0, 3, 4, 5, 6, 7, 8]),
    ("to_base64", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("to_bin", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("to_char", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("to_date", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("to_days", &[0]),
    ("to_hex", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("to_json", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("to_jsonb", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("to_number", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("to_oct", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("to_timestamp", &[0, 3, 4, 5, 6, 7, 8]),
    ("to_tsquery", &[0, 3, 4, 5, 6, 7, 8]),
    ("to_tsvector", &[0, 3, 4, 5, 6, 7, 8]),
    ("translate", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("trim", &[0, 3, 4, 5, 6, 7, 8]),
    ("trim_array", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("trim_scale", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("trunc", &[0, 3, 4, 5, 6, 7, 8]),
    ("truncate", &[0, 3, 4, 5, 6, 7, 8]),
    ("ts_delete", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("ts_filter", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("ts_headline", &[0, 1, 5, 6, 7, 8]),
    ("ts_lexize", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("ts_rewrite", &[0, 1, 2, 4, 5, 6, 7, 8]),
    ("tsquery_and", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("tsquery_not", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("tsquery_or", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("tsquery_phrase", &[0, 1, 4, 5, 6, 7, 8]),
    ("tsrange", &[0, 1, 4, 5, 6, 7, 8]),
    ("tstzrange", &[0, 1, 4, 5, 6, 7, 8]),
    ("tsvector_length", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("tsvector_to_array", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("txid_status", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("ucase", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("unhex", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("unistr", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("unix_timestamp", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("upper", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("upper_inc", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("upper_inf", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("uuid_extract_timestamp", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("uuid_extract_version", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("uuid_generate_v3", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("uuid_generate_v4", &[1, 2, 3, 4, 5, 6, 7, 8]),
    ("uuid_generate_v5", &[0, 1, 3, 4, 5, 6, 7, 8]),
    ("uuid_generate_v7", &[2, 3, 4, 5, 6, 7, 8]),
    ("uuid_nil", &[1, 2, 3, 4, 5, 6, 7, 8]),
    ("uuidv7", &[2, 3, 4, 5, 6, 7, 8]),
    ("verify_heapam", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("websearch_to_tsquery", &[0, 3, 4, 5, 6, 7, 8]),
    ("week", &[0]),
    ("weekday", &[0]),
    ("weekofyear", &[0]),
    ("width_bucket", &[0, 1, 3, 5, 6, 7, 8]),
    ("xid8_larger", &[0]),
    ("xid8_smaller", &[0]),
    ("xml_is_well_formed_content", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("xmlcomment", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("xmltext", &[0, 2, 3, 4, 5, 6, 7, 8]),
    ("year", &[0]),
    ("yearweek", &[0]),
];