Migrate the former contrib/txid module into core. This will make it easier
[PostgreSQL.git] / src / include / utils / builtins.h
blob04237d907a12d7220cf0ed39dff24a74b32271c1
1 /*-------------------------------------------------------------------------
3 * builtins.h
4 * Declarations for operations on built-in types.
7 * Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group
8 * Portions Copyright (c) 1994, Regents of the University of California
10 * $PostgreSQL$
12 *-------------------------------------------------------------------------
14 #ifndef BUILTINS_H
15 #define BUILTINS_H
17 #include "fmgr.h"
18 #include "nodes/parsenodes.h"
21 * Defined in adt/
24 /* acl.c */
25 extern Datum has_table_privilege_name_name(PG_FUNCTION_ARGS);
26 extern Datum has_table_privilege_name_id(PG_FUNCTION_ARGS);
27 extern Datum has_table_privilege_id_name(PG_FUNCTION_ARGS);
28 extern Datum has_table_privilege_id_id(PG_FUNCTION_ARGS);
29 extern Datum has_table_privilege_name(PG_FUNCTION_ARGS);
30 extern Datum has_table_privilege_id(PG_FUNCTION_ARGS);
31 extern Datum has_database_privilege_name_name(PG_FUNCTION_ARGS);
32 extern Datum has_database_privilege_name_id(PG_FUNCTION_ARGS);
33 extern Datum has_database_privilege_id_name(PG_FUNCTION_ARGS);
34 extern Datum has_database_privilege_id_id(PG_FUNCTION_ARGS);
35 extern Datum has_database_privilege_name(PG_FUNCTION_ARGS);
36 extern Datum has_database_privilege_id(PG_FUNCTION_ARGS);
37 extern Datum has_function_privilege_name_name(PG_FUNCTION_ARGS);
38 extern Datum has_function_privilege_name_id(PG_FUNCTION_ARGS);
39 extern Datum has_function_privilege_id_name(PG_FUNCTION_ARGS);
40 extern Datum has_function_privilege_id_id(PG_FUNCTION_ARGS);
41 extern Datum has_function_privilege_name(PG_FUNCTION_ARGS);
42 extern Datum has_function_privilege_id(PG_FUNCTION_ARGS);
43 extern Datum has_language_privilege_name_name(PG_FUNCTION_ARGS);
44 extern Datum has_language_privilege_name_id(PG_FUNCTION_ARGS);
45 extern Datum has_language_privilege_id_name(PG_FUNCTION_ARGS);
46 extern Datum has_language_privilege_id_id(PG_FUNCTION_ARGS);
47 extern Datum has_language_privilege_name(PG_FUNCTION_ARGS);
48 extern Datum has_language_privilege_id(PG_FUNCTION_ARGS);
49 extern Datum has_schema_privilege_name_name(PG_FUNCTION_ARGS);
50 extern Datum has_schema_privilege_name_id(PG_FUNCTION_ARGS);
51 extern Datum has_schema_privilege_id_name(PG_FUNCTION_ARGS);
52 extern Datum has_schema_privilege_id_id(PG_FUNCTION_ARGS);
53 extern Datum has_schema_privilege_name(PG_FUNCTION_ARGS);
54 extern Datum has_schema_privilege_id(PG_FUNCTION_ARGS);
55 extern Datum has_tablespace_privilege_name_name(PG_FUNCTION_ARGS);
56 extern Datum has_tablespace_privilege_name_id(PG_FUNCTION_ARGS);
57 extern Datum has_tablespace_privilege_id_name(PG_FUNCTION_ARGS);
58 extern Datum has_tablespace_privilege_id_id(PG_FUNCTION_ARGS);
59 extern Datum has_tablespace_privilege_name(PG_FUNCTION_ARGS);
60 extern Datum has_tablespace_privilege_id(PG_FUNCTION_ARGS);
61 extern Datum pg_has_role_name_name(PG_FUNCTION_ARGS);
62 extern Datum pg_has_role_name_id(PG_FUNCTION_ARGS);
63 extern Datum pg_has_role_id_name(PG_FUNCTION_ARGS);
64 extern Datum pg_has_role_id_id(PG_FUNCTION_ARGS);
65 extern Datum pg_has_role_name(PG_FUNCTION_ARGS);
66 extern Datum pg_has_role_id(PG_FUNCTION_ARGS);
68 /* bool.c */
69 extern Datum boolin(PG_FUNCTION_ARGS);
70 extern Datum boolout(PG_FUNCTION_ARGS);
71 extern Datum boolrecv(PG_FUNCTION_ARGS);
72 extern Datum boolsend(PG_FUNCTION_ARGS);
73 extern Datum booltext(PG_FUNCTION_ARGS);
74 extern Datum booleq(PG_FUNCTION_ARGS);
75 extern Datum boolne(PG_FUNCTION_ARGS);
76 extern Datum boollt(PG_FUNCTION_ARGS);
77 extern Datum boolgt(PG_FUNCTION_ARGS);
78 extern Datum boolle(PG_FUNCTION_ARGS);
79 extern Datum boolge(PG_FUNCTION_ARGS);
80 extern Datum istrue(PG_FUNCTION_ARGS);
81 extern Datum isfalse(PG_FUNCTION_ARGS);
82 extern Datum isnottrue(PG_FUNCTION_ARGS);
83 extern Datum isnotfalse(PG_FUNCTION_ARGS);
84 extern Datum booland_statefunc(PG_FUNCTION_ARGS);
85 extern Datum boolor_statefunc(PG_FUNCTION_ARGS);
87 /* char.c */
88 extern Datum charin(PG_FUNCTION_ARGS);
89 extern Datum charout(PG_FUNCTION_ARGS);
90 extern Datum charrecv(PG_FUNCTION_ARGS);
91 extern Datum charsend(PG_FUNCTION_ARGS);
92 extern Datum chareq(PG_FUNCTION_ARGS);
93 extern Datum charne(PG_FUNCTION_ARGS);
94 extern Datum charlt(PG_FUNCTION_ARGS);
95 extern Datum charle(PG_FUNCTION_ARGS);
96 extern Datum chargt(PG_FUNCTION_ARGS);
97 extern Datum charge(PG_FUNCTION_ARGS);
98 extern Datum chartoi4(PG_FUNCTION_ARGS);
99 extern Datum i4tochar(PG_FUNCTION_ARGS);
100 extern Datum text_char(PG_FUNCTION_ARGS);
101 extern Datum char_text(PG_FUNCTION_ARGS);
103 /* domains.c */
104 extern Datum domain_in(PG_FUNCTION_ARGS);
105 extern Datum domain_recv(PG_FUNCTION_ARGS);
107 /* enum.c */
108 extern Datum enum_in(PG_FUNCTION_ARGS);
109 extern Datum enum_out(PG_FUNCTION_ARGS);
110 extern Datum enum_recv(PG_FUNCTION_ARGS);
111 extern Datum enum_send(PG_FUNCTION_ARGS);
112 extern Datum enum_lt(PG_FUNCTION_ARGS);
113 extern Datum enum_le(PG_FUNCTION_ARGS);
114 extern Datum enum_eq(PG_FUNCTION_ARGS);
115 extern Datum enum_ne(PG_FUNCTION_ARGS);
116 extern Datum enum_ge(PG_FUNCTION_ARGS);
117 extern Datum enum_gt(PG_FUNCTION_ARGS);
118 extern Datum enum_cmp(PG_FUNCTION_ARGS);
119 extern Datum enum_smaller(PG_FUNCTION_ARGS);
120 extern Datum enum_larger(PG_FUNCTION_ARGS);
121 extern Datum enum_first(PG_FUNCTION_ARGS);
122 extern Datum enum_last(PG_FUNCTION_ARGS);
123 extern Datum enum_range_bounds(PG_FUNCTION_ARGS);
124 extern Datum enum_range_all(PG_FUNCTION_ARGS);
126 /* int.c */
127 extern Datum int2in(PG_FUNCTION_ARGS);
128 extern Datum int2out(PG_FUNCTION_ARGS);
129 extern Datum int2recv(PG_FUNCTION_ARGS);
130 extern Datum int2send(PG_FUNCTION_ARGS);
131 extern Datum int2vectorin(PG_FUNCTION_ARGS);
132 extern Datum int2vectorout(PG_FUNCTION_ARGS);
133 extern Datum int2vectorrecv(PG_FUNCTION_ARGS);
134 extern Datum int2vectorsend(PG_FUNCTION_ARGS);
135 extern Datum int2vectoreq(PG_FUNCTION_ARGS);
136 extern Datum int4in(PG_FUNCTION_ARGS);
137 extern Datum int4out(PG_FUNCTION_ARGS);
138 extern Datum int4recv(PG_FUNCTION_ARGS);
139 extern Datum int4send(PG_FUNCTION_ARGS);
140 extern Datum i2toi4(PG_FUNCTION_ARGS);
141 extern Datum i4toi2(PG_FUNCTION_ARGS);
142 extern Datum int4_bool(PG_FUNCTION_ARGS);
143 extern Datum bool_int4(PG_FUNCTION_ARGS);
144 extern Datum int4eq(PG_FUNCTION_ARGS);
145 extern Datum int4ne(PG_FUNCTION_ARGS);
146 extern Datum int4lt(PG_FUNCTION_ARGS);
147 extern Datum int4le(PG_FUNCTION_ARGS);
148 extern Datum int4gt(PG_FUNCTION_ARGS);
149 extern Datum int4ge(PG_FUNCTION_ARGS);
150 extern Datum int2eq(PG_FUNCTION_ARGS);
151 extern Datum int2ne(PG_FUNCTION_ARGS);
152 extern Datum int2lt(PG_FUNCTION_ARGS);
153 extern Datum int2le(PG_FUNCTION_ARGS);
154 extern Datum int2gt(PG_FUNCTION_ARGS);
155 extern Datum int2ge(PG_FUNCTION_ARGS);
156 extern Datum int24eq(PG_FUNCTION_ARGS);
157 extern Datum int24ne(PG_FUNCTION_ARGS);
158 extern Datum int24lt(PG_FUNCTION_ARGS);
159 extern Datum int24le(PG_FUNCTION_ARGS);
160 extern Datum int24gt(PG_FUNCTION_ARGS);
161 extern Datum int24ge(PG_FUNCTION_ARGS);
162 extern Datum int42eq(PG_FUNCTION_ARGS);
163 extern Datum int42ne(PG_FUNCTION_ARGS);
164 extern Datum int42lt(PG_FUNCTION_ARGS);
165 extern Datum int42le(PG_FUNCTION_ARGS);
166 extern Datum int42gt(PG_FUNCTION_ARGS);
167 extern Datum int42ge(PG_FUNCTION_ARGS);
168 extern Datum int4um(PG_FUNCTION_ARGS);
169 extern Datum int4up(PG_FUNCTION_ARGS);
170 extern Datum int4pl(PG_FUNCTION_ARGS);
171 extern Datum int4mi(PG_FUNCTION_ARGS);
172 extern Datum int4mul(PG_FUNCTION_ARGS);
173 extern Datum int4div(PG_FUNCTION_ARGS);
174 extern Datum int4abs(PG_FUNCTION_ARGS);
175 extern Datum int4inc(PG_FUNCTION_ARGS);
176 extern Datum int2um(PG_FUNCTION_ARGS);
177 extern Datum int2up(PG_FUNCTION_ARGS);
178 extern Datum int2pl(PG_FUNCTION_ARGS);
179 extern Datum int2mi(PG_FUNCTION_ARGS);
180 extern Datum int2mul(PG_FUNCTION_ARGS);
181 extern Datum int2div(PG_FUNCTION_ARGS);
182 extern Datum int2abs(PG_FUNCTION_ARGS);
183 extern Datum int24pl(PG_FUNCTION_ARGS);
184 extern Datum int24mi(PG_FUNCTION_ARGS);
185 extern Datum int24mul(PG_FUNCTION_ARGS);
186 extern Datum int24div(PG_FUNCTION_ARGS);
187 extern Datum int42pl(PG_FUNCTION_ARGS);
188 extern Datum int42mi(PG_FUNCTION_ARGS);
189 extern Datum int42mul(PG_FUNCTION_ARGS);
190 extern Datum int42div(PG_FUNCTION_ARGS);
191 extern Datum int4mod(PG_FUNCTION_ARGS);
192 extern Datum int2mod(PG_FUNCTION_ARGS);
193 extern Datum int24mod(PG_FUNCTION_ARGS);
194 extern Datum int42mod(PG_FUNCTION_ARGS);
195 extern Datum int2larger(PG_FUNCTION_ARGS);
196 extern Datum int2smaller(PG_FUNCTION_ARGS);
197 extern Datum int4larger(PG_FUNCTION_ARGS);
198 extern Datum int4smaller(PG_FUNCTION_ARGS);
200 extern Datum int4and(PG_FUNCTION_ARGS);
201 extern Datum int4or(PG_FUNCTION_ARGS);
202 extern Datum int4xor(PG_FUNCTION_ARGS);
203 extern Datum int4not(PG_FUNCTION_ARGS);
204 extern Datum int4shl(PG_FUNCTION_ARGS);
205 extern Datum int4shr(PG_FUNCTION_ARGS);
206 extern Datum int2and(PG_FUNCTION_ARGS);
207 extern Datum int2or(PG_FUNCTION_ARGS);
208 extern Datum int2xor(PG_FUNCTION_ARGS);
209 extern Datum int2not(PG_FUNCTION_ARGS);
210 extern Datum int2shl(PG_FUNCTION_ARGS);
211 extern Datum int2shr(PG_FUNCTION_ARGS);
212 extern Datum generate_series_int4(PG_FUNCTION_ARGS);
213 extern Datum generate_series_step_int4(PG_FUNCTION_ARGS);
214 extern int2vector *buildint2vector(const int2 *int2s, int n);
216 /* name.c */
217 extern Datum namein(PG_FUNCTION_ARGS);
218 extern Datum nameout(PG_FUNCTION_ARGS);
219 extern Datum namerecv(PG_FUNCTION_ARGS);
220 extern Datum namesend(PG_FUNCTION_ARGS);
221 extern Datum nameeq(PG_FUNCTION_ARGS);
222 extern Datum namene(PG_FUNCTION_ARGS);
223 extern Datum namelt(PG_FUNCTION_ARGS);
224 extern Datum namele(PG_FUNCTION_ARGS);
225 extern Datum namegt(PG_FUNCTION_ARGS);
226 extern Datum namege(PG_FUNCTION_ARGS);
227 extern Datum name_pattern_eq(PG_FUNCTION_ARGS);
228 extern Datum name_pattern_ne(PG_FUNCTION_ARGS);
229 extern Datum name_pattern_lt(PG_FUNCTION_ARGS);
230 extern Datum name_pattern_le(PG_FUNCTION_ARGS);
231 extern Datum name_pattern_gt(PG_FUNCTION_ARGS);
232 extern Datum name_pattern_ge(PG_FUNCTION_ARGS);
233 extern int namecpy(Name n1, Name n2);
234 extern int namestrcpy(Name name, const char *str);
235 extern int namestrcmp(Name name, const char *str);
236 extern Datum current_user(PG_FUNCTION_ARGS);
237 extern Datum session_user(PG_FUNCTION_ARGS);
238 extern Datum current_schema(PG_FUNCTION_ARGS);
239 extern Datum current_schemas(PG_FUNCTION_ARGS);
241 /* numutils.c */
242 extern int32 pg_atoi(char *s, int size, int c);
243 extern void pg_itoa(int16 i, char *a);
244 extern void pg_ltoa(int32 l, char *a);
247 * Per-opclass comparison functions for new btrees. These are
248 * stored in pg_amproc and defined in access/nbtree/nbtcompare.c
250 extern Datum btboolcmp(PG_FUNCTION_ARGS);
251 extern Datum btint2cmp(PG_FUNCTION_ARGS);
252 extern Datum btint4cmp(PG_FUNCTION_ARGS);
253 extern Datum btint8cmp(PG_FUNCTION_ARGS);
254 extern Datum btfloat4cmp(PG_FUNCTION_ARGS);
255 extern Datum btfloat8cmp(PG_FUNCTION_ARGS);
256 extern Datum btint48cmp(PG_FUNCTION_ARGS);
257 extern Datum btint84cmp(PG_FUNCTION_ARGS);
258 extern Datum btint24cmp(PG_FUNCTION_ARGS);
259 extern Datum btint42cmp(PG_FUNCTION_ARGS);
260 extern Datum btint28cmp(PG_FUNCTION_ARGS);
261 extern Datum btint82cmp(PG_FUNCTION_ARGS);
262 extern Datum btfloat48cmp(PG_FUNCTION_ARGS);
263 extern Datum btfloat84cmp(PG_FUNCTION_ARGS);
264 extern Datum btoidcmp(PG_FUNCTION_ARGS);
265 extern Datum btoidvectorcmp(PG_FUNCTION_ARGS);
266 extern Datum btabstimecmp(PG_FUNCTION_ARGS);
267 extern Datum btreltimecmp(PG_FUNCTION_ARGS);
268 extern Datum bttintervalcmp(PG_FUNCTION_ARGS);
269 extern Datum btcharcmp(PG_FUNCTION_ARGS);
270 extern Datum btnamecmp(PG_FUNCTION_ARGS);
271 extern Datum bttextcmp(PG_FUNCTION_ARGS);
272 extern Datum btname_pattern_cmp(PG_FUNCTION_ARGS);
273 extern Datum bttext_pattern_cmp(PG_FUNCTION_ARGS);
275 /* float.c */
276 extern PGDLLIMPORT int extra_float_digits;
278 extern double get_float8_infinity(void);
279 extern float get_float4_infinity(void);
280 extern double get_float8_nan(void);
281 extern float get_float4_nan(void);
282 extern int is_infinite(double val);
284 extern Datum float4in(PG_FUNCTION_ARGS);
285 extern Datum float4out(PG_FUNCTION_ARGS);
286 extern Datum float4recv(PG_FUNCTION_ARGS);
287 extern Datum float4send(PG_FUNCTION_ARGS);
288 extern Datum float8in(PG_FUNCTION_ARGS);
289 extern Datum float8out(PG_FUNCTION_ARGS);
290 extern Datum float8recv(PG_FUNCTION_ARGS);
291 extern Datum float8send(PG_FUNCTION_ARGS);
292 extern Datum float4abs(PG_FUNCTION_ARGS);
293 extern Datum float4um(PG_FUNCTION_ARGS);
294 extern Datum float4up(PG_FUNCTION_ARGS);
295 extern Datum float4larger(PG_FUNCTION_ARGS);
296 extern Datum float4smaller(PG_FUNCTION_ARGS);
297 extern Datum float8abs(PG_FUNCTION_ARGS);
298 extern Datum float8um(PG_FUNCTION_ARGS);
299 extern Datum float8up(PG_FUNCTION_ARGS);
300 extern Datum float8larger(PG_FUNCTION_ARGS);
301 extern Datum float8smaller(PG_FUNCTION_ARGS);
302 extern Datum float4pl(PG_FUNCTION_ARGS);
303 extern Datum float4mi(PG_FUNCTION_ARGS);
304 extern Datum float4mul(PG_FUNCTION_ARGS);
305 extern Datum float4div(PG_FUNCTION_ARGS);
306 extern Datum float8pl(PG_FUNCTION_ARGS);
307 extern Datum float8mi(PG_FUNCTION_ARGS);
308 extern Datum float8mul(PG_FUNCTION_ARGS);
309 extern Datum float8div(PG_FUNCTION_ARGS);
310 extern Datum float4eq(PG_FUNCTION_ARGS);
311 extern Datum float4ne(PG_FUNCTION_ARGS);
312 extern Datum float4lt(PG_FUNCTION_ARGS);
313 extern Datum float4le(PG_FUNCTION_ARGS);
314 extern Datum float4gt(PG_FUNCTION_ARGS);
315 extern Datum float4ge(PG_FUNCTION_ARGS);
316 extern Datum float8eq(PG_FUNCTION_ARGS);
317 extern Datum float8ne(PG_FUNCTION_ARGS);
318 extern Datum float8lt(PG_FUNCTION_ARGS);
319 extern Datum float8le(PG_FUNCTION_ARGS);
320 extern Datum float8gt(PG_FUNCTION_ARGS);
321 extern Datum float8ge(PG_FUNCTION_ARGS);
322 extern Datum ftod(PG_FUNCTION_ARGS);
323 extern Datum i4tod(PG_FUNCTION_ARGS);
324 extern Datum i2tod(PG_FUNCTION_ARGS);
325 extern Datum dtof(PG_FUNCTION_ARGS);
326 extern Datum dtoi4(PG_FUNCTION_ARGS);
327 extern Datum dtoi2(PG_FUNCTION_ARGS);
328 extern Datum i4tof(PG_FUNCTION_ARGS);
329 extern Datum i2tof(PG_FUNCTION_ARGS);
330 extern Datum ftoi4(PG_FUNCTION_ARGS);
331 extern Datum ftoi2(PG_FUNCTION_ARGS);
332 extern Datum dround(PG_FUNCTION_ARGS);
333 extern Datum dceil(PG_FUNCTION_ARGS);
334 extern Datum dfloor(PG_FUNCTION_ARGS);
335 extern Datum dsign(PG_FUNCTION_ARGS);
336 extern Datum dtrunc(PG_FUNCTION_ARGS);
337 extern Datum dsqrt(PG_FUNCTION_ARGS);
338 extern Datum dcbrt(PG_FUNCTION_ARGS);
339 extern Datum dpow(PG_FUNCTION_ARGS);
340 extern Datum dexp(PG_FUNCTION_ARGS);
341 extern Datum dlog1(PG_FUNCTION_ARGS);
342 extern Datum dlog10(PG_FUNCTION_ARGS);
343 extern Datum dacos(PG_FUNCTION_ARGS);
344 extern Datum dasin(PG_FUNCTION_ARGS);
345 extern Datum datan(PG_FUNCTION_ARGS);
346 extern Datum datan2(PG_FUNCTION_ARGS);
347 extern Datum dcos(PG_FUNCTION_ARGS);
348 extern Datum dcot(PG_FUNCTION_ARGS);
349 extern Datum dsin(PG_FUNCTION_ARGS);
350 extern Datum dtan(PG_FUNCTION_ARGS);
351 extern Datum degrees(PG_FUNCTION_ARGS);
352 extern Datum dpi(PG_FUNCTION_ARGS);
353 extern Datum radians(PG_FUNCTION_ARGS);
354 extern Datum drandom(PG_FUNCTION_ARGS);
355 extern Datum setseed(PG_FUNCTION_ARGS);
356 extern Datum float8_accum(PG_FUNCTION_ARGS);
357 extern Datum float4_accum(PG_FUNCTION_ARGS);
358 extern Datum float8_avg(PG_FUNCTION_ARGS);
359 extern Datum float8_var_pop(PG_FUNCTION_ARGS);
360 extern Datum float8_var_samp(PG_FUNCTION_ARGS);
361 extern Datum float8_stddev_pop(PG_FUNCTION_ARGS);
362 extern Datum float8_stddev_samp(PG_FUNCTION_ARGS);
363 extern Datum float8_regr_accum(PG_FUNCTION_ARGS);
364 extern Datum float8_regr_sxx(PG_FUNCTION_ARGS);
365 extern Datum float8_regr_syy(PG_FUNCTION_ARGS);
366 extern Datum float8_regr_sxy(PG_FUNCTION_ARGS);
367 extern Datum float8_regr_avgx(PG_FUNCTION_ARGS);
368 extern Datum float8_regr_avgy(PG_FUNCTION_ARGS);
369 extern Datum float8_covar_pop(PG_FUNCTION_ARGS);
370 extern Datum float8_covar_samp(PG_FUNCTION_ARGS);
371 extern Datum float8_corr(PG_FUNCTION_ARGS);
372 extern Datum float8_regr_r2(PG_FUNCTION_ARGS);
373 extern Datum float8_regr_slope(PG_FUNCTION_ARGS);
374 extern Datum float8_regr_intercept(PG_FUNCTION_ARGS);
375 extern Datum float48pl(PG_FUNCTION_ARGS);
376 extern Datum float48mi(PG_FUNCTION_ARGS);
377 extern Datum float48mul(PG_FUNCTION_ARGS);
378 extern Datum float48div(PG_FUNCTION_ARGS);
379 extern Datum float84pl(PG_FUNCTION_ARGS);
380 extern Datum float84mi(PG_FUNCTION_ARGS);
381 extern Datum float84mul(PG_FUNCTION_ARGS);
382 extern Datum float84div(PG_FUNCTION_ARGS);
383 extern Datum float48eq(PG_FUNCTION_ARGS);
384 extern Datum float48ne(PG_FUNCTION_ARGS);
385 extern Datum float48lt(PG_FUNCTION_ARGS);
386 extern Datum float48le(PG_FUNCTION_ARGS);
387 extern Datum float48gt(PG_FUNCTION_ARGS);
388 extern Datum float48ge(PG_FUNCTION_ARGS);
389 extern Datum float84eq(PG_FUNCTION_ARGS);
390 extern Datum float84ne(PG_FUNCTION_ARGS);
391 extern Datum float84lt(PG_FUNCTION_ARGS);
392 extern Datum float84le(PG_FUNCTION_ARGS);
393 extern Datum float84gt(PG_FUNCTION_ARGS);
394 extern Datum float84ge(PG_FUNCTION_ARGS);
395 extern Datum width_bucket_float8(PG_FUNCTION_ARGS);
397 /* dbsize.c */
398 extern Datum pg_tablespace_size_oid(PG_FUNCTION_ARGS);
399 extern Datum pg_tablespace_size_name(PG_FUNCTION_ARGS);
400 extern Datum pg_database_size_oid(PG_FUNCTION_ARGS);
401 extern Datum pg_database_size_name(PG_FUNCTION_ARGS);
402 extern Datum pg_relation_size_oid(PG_FUNCTION_ARGS);
403 extern Datum pg_relation_size_name(PG_FUNCTION_ARGS);
404 extern Datum pg_total_relation_size_oid(PG_FUNCTION_ARGS);
405 extern Datum pg_total_relation_size_name(PG_FUNCTION_ARGS);
406 extern Datum pg_size_pretty(PG_FUNCTION_ARGS);
408 /* genfile.c */
409 extern Datum pg_stat_file(PG_FUNCTION_ARGS);
410 extern Datum pg_read_file(PG_FUNCTION_ARGS);
411 extern Datum pg_ls_dir(PG_FUNCTION_ARGS);
413 /* misc.c */
414 extern Datum nullvalue(PG_FUNCTION_ARGS);
415 extern Datum nonnullvalue(PG_FUNCTION_ARGS);
416 extern Datum current_database(PG_FUNCTION_ARGS);
417 extern Datum pg_cancel_backend(PG_FUNCTION_ARGS);
418 extern Datum pg_reload_conf(PG_FUNCTION_ARGS);
419 extern Datum pg_tablespace_databases(PG_FUNCTION_ARGS);
420 extern Datum pg_rotate_logfile(PG_FUNCTION_ARGS);
421 extern Datum pg_sleep(PG_FUNCTION_ARGS);
423 /* oid.c */
424 extern Datum oidin(PG_FUNCTION_ARGS);
425 extern Datum oidout(PG_FUNCTION_ARGS);
426 extern Datum oidrecv(PG_FUNCTION_ARGS);
427 extern Datum oidsend(PG_FUNCTION_ARGS);
428 extern Datum oideq(PG_FUNCTION_ARGS);
429 extern Datum oidne(PG_FUNCTION_ARGS);
430 extern Datum oidlt(PG_FUNCTION_ARGS);
431 extern Datum oidle(PG_FUNCTION_ARGS);
432 extern Datum oidge(PG_FUNCTION_ARGS);
433 extern Datum oidgt(PG_FUNCTION_ARGS);
434 extern Datum oidlarger(PG_FUNCTION_ARGS);
435 extern Datum oidsmaller(PG_FUNCTION_ARGS);
436 extern Datum oidvectorin(PG_FUNCTION_ARGS);
437 extern Datum oidvectorout(PG_FUNCTION_ARGS);
438 extern Datum oidvectorrecv(PG_FUNCTION_ARGS);
439 extern Datum oidvectorsend(PG_FUNCTION_ARGS);
440 extern Datum oidvectoreq(PG_FUNCTION_ARGS);
441 extern Datum oidvectorne(PG_FUNCTION_ARGS);
442 extern Datum oidvectorlt(PG_FUNCTION_ARGS);
443 extern Datum oidvectorle(PG_FUNCTION_ARGS);
444 extern Datum oidvectorge(PG_FUNCTION_ARGS);
445 extern Datum oidvectorgt(PG_FUNCTION_ARGS);
446 extern oidvector *buildoidvector(const Oid *oids, int n);
448 /* pseudotypes.c */
449 extern Datum cstring_in(PG_FUNCTION_ARGS);
450 extern Datum cstring_out(PG_FUNCTION_ARGS);
451 extern Datum cstring_recv(PG_FUNCTION_ARGS);
452 extern Datum cstring_send(PG_FUNCTION_ARGS);
453 extern Datum any_in(PG_FUNCTION_ARGS);
454 extern Datum any_out(PG_FUNCTION_ARGS);
455 extern Datum anyarray_in(PG_FUNCTION_ARGS);
456 extern Datum anyarray_out(PG_FUNCTION_ARGS);
457 extern Datum anyarray_recv(PG_FUNCTION_ARGS);
458 extern Datum anyarray_send(PG_FUNCTION_ARGS);
459 extern Datum anynonarray_in(PG_FUNCTION_ARGS);
460 extern Datum anynonarray_out(PG_FUNCTION_ARGS);
461 extern Datum anyenum_in(PG_FUNCTION_ARGS);
462 extern Datum anyenum_out(PG_FUNCTION_ARGS);
463 extern Datum void_in(PG_FUNCTION_ARGS);
464 extern Datum void_out(PG_FUNCTION_ARGS);
465 extern Datum trigger_in(PG_FUNCTION_ARGS);
466 extern Datum trigger_out(PG_FUNCTION_ARGS);
467 extern Datum language_handler_in(PG_FUNCTION_ARGS);
468 extern Datum language_handler_out(PG_FUNCTION_ARGS);
469 extern Datum internal_in(PG_FUNCTION_ARGS);
470 extern Datum internal_out(PG_FUNCTION_ARGS);
471 extern Datum opaque_in(PG_FUNCTION_ARGS);
472 extern Datum opaque_out(PG_FUNCTION_ARGS);
473 extern Datum anyelement_in(PG_FUNCTION_ARGS);
474 extern Datum anyelement_out(PG_FUNCTION_ARGS);
475 extern Datum shell_in(PG_FUNCTION_ARGS);
476 extern Datum shell_out(PG_FUNCTION_ARGS);
478 /* regexp.c */
479 extern Datum nameregexeq(PG_FUNCTION_ARGS);
480 extern Datum nameregexne(PG_FUNCTION_ARGS);
481 extern Datum textregexeq(PG_FUNCTION_ARGS);
482 extern Datum textregexne(PG_FUNCTION_ARGS);
483 extern Datum nameicregexeq(PG_FUNCTION_ARGS);
484 extern Datum nameicregexne(PG_FUNCTION_ARGS);
485 extern Datum texticregexeq(PG_FUNCTION_ARGS);
486 extern Datum texticregexne(PG_FUNCTION_ARGS);
487 extern Datum textregexsubstr(PG_FUNCTION_ARGS);
488 extern Datum textregexreplace_noopt(PG_FUNCTION_ARGS);
489 extern Datum textregexreplace(PG_FUNCTION_ARGS);
490 extern Datum similar_escape(PG_FUNCTION_ARGS);
491 extern Datum regexp_matches(PG_FUNCTION_ARGS);
492 extern Datum regexp_matches_no_flags(PG_FUNCTION_ARGS);
493 extern Datum regexp_split_to_table(PG_FUNCTION_ARGS);
494 extern Datum regexp_split_to_table_no_flags(PG_FUNCTION_ARGS);
495 extern Datum regexp_split_to_array(PG_FUNCTION_ARGS);
496 extern Datum regexp_split_to_array_no_flags(PG_FUNCTION_ARGS);
497 extern bool regex_flavor_is_basic(void);
499 /* regproc.c */
500 extern Datum regprocin(PG_FUNCTION_ARGS);
501 extern Datum regprocout(PG_FUNCTION_ARGS);
502 extern Datum regprocrecv(PG_FUNCTION_ARGS);
503 extern Datum regprocsend(PG_FUNCTION_ARGS);
504 extern Datum regprocedurein(PG_FUNCTION_ARGS);
505 extern Datum regprocedureout(PG_FUNCTION_ARGS);
506 extern Datum regprocedurerecv(PG_FUNCTION_ARGS);
507 extern Datum regproceduresend(PG_FUNCTION_ARGS);
508 extern Datum regoperin(PG_FUNCTION_ARGS);
509 extern Datum regoperout(PG_FUNCTION_ARGS);
510 extern Datum regoperrecv(PG_FUNCTION_ARGS);
511 extern Datum regopersend(PG_FUNCTION_ARGS);
512 extern Datum regoperatorin(PG_FUNCTION_ARGS);
513 extern Datum regoperatorout(PG_FUNCTION_ARGS);
514 extern Datum regoperatorrecv(PG_FUNCTION_ARGS);
515 extern Datum regoperatorsend(PG_FUNCTION_ARGS);
516 extern Datum regclassin(PG_FUNCTION_ARGS);
517 extern Datum regclassout(PG_FUNCTION_ARGS);
518 extern Datum regclassrecv(PG_FUNCTION_ARGS);
519 extern Datum regclasssend(PG_FUNCTION_ARGS);
520 extern Datum regtypein(PG_FUNCTION_ARGS);
521 extern Datum regtypeout(PG_FUNCTION_ARGS);
522 extern Datum regtyperecv(PG_FUNCTION_ARGS);
523 extern Datum regtypesend(PG_FUNCTION_ARGS);
524 extern Datum regconfigin(PG_FUNCTION_ARGS);
525 extern Datum regconfigout(PG_FUNCTION_ARGS);
526 extern Datum regconfigrecv(PG_FUNCTION_ARGS);
527 extern Datum regconfigsend(PG_FUNCTION_ARGS);
528 extern Datum regdictionaryin(PG_FUNCTION_ARGS);
529 extern Datum regdictionaryout(PG_FUNCTION_ARGS);
530 extern Datum regdictionaryrecv(PG_FUNCTION_ARGS);
531 extern Datum regdictionarysend(PG_FUNCTION_ARGS);
532 extern Datum text_regclass(PG_FUNCTION_ARGS);
533 extern List *stringToQualifiedNameList(const char *string);
534 extern char *format_procedure(Oid procedure_oid);
535 extern char *format_operator(Oid operator_oid);
537 /* rowtypes.c */
538 extern Datum record_in(PG_FUNCTION_ARGS);
539 extern Datum record_out(PG_FUNCTION_ARGS);
540 extern Datum record_recv(PG_FUNCTION_ARGS);
541 extern Datum record_send(PG_FUNCTION_ARGS);
543 /* ruleutils.c */
544 extern Datum pg_get_ruledef(PG_FUNCTION_ARGS);
545 extern Datum pg_get_ruledef_ext(PG_FUNCTION_ARGS);
546 extern Datum pg_get_viewdef(PG_FUNCTION_ARGS);
547 extern Datum pg_get_viewdef_ext(PG_FUNCTION_ARGS);
548 extern Datum pg_get_viewdef_name(PG_FUNCTION_ARGS);
549 extern Datum pg_get_viewdef_name_ext(PG_FUNCTION_ARGS);
550 extern Datum pg_get_indexdef(PG_FUNCTION_ARGS);
551 extern Datum pg_get_indexdef_ext(PG_FUNCTION_ARGS);
552 extern char *pg_get_indexdef_string(Oid indexrelid);
553 extern Datum pg_get_triggerdef(PG_FUNCTION_ARGS);
554 extern Datum pg_get_constraintdef(PG_FUNCTION_ARGS);
555 extern Datum pg_get_constraintdef_ext(PG_FUNCTION_ARGS);
556 extern char *pg_get_constraintdef_string(Oid constraintId);
557 extern Datum pg_get_expr(PG_FUNCTION_ARGS);
558 extern Datum pg_get_expr_ext(PG_FUNCTION_ARGS);
559 extern Datum pg_get_userbyid(PG_FUNCTION_ARGS);
560 extern Datum pg_get_serial_sequence(PG_FUNCTION_ARGS);
561 extern char *deparse_expression(Node *expr, List *dpcontext,
562 bool forceprefix, bool showimplicit);
563 extern List *deparse_context_for(const char *aliasname, Oid relid);
564 extern List *deparse_context_for_plan(Node *outer_plan, Node *inner_plan,
565 List *rtable);
566 extern const char *quote_identifier(const char *ident);
567 extern char *quote_qualified_identifier(const char *namespace,
568 const char *ident);
569 extern char *flatten_reloptions(Oid relid);
570 extern Datum unflatten_reloptions(char *reloptstring);
572 /* tid.c */
573 extern Datum tidin(PG_FUNCTION_ARGS);
574 extern Datum tidout(PG_FUNCTION_ARGS);
575 extern Datum tidrecv(PG_FUNCTION_ARGS);
576 extern Datum tidsend(PG_FUNCTION_ARGS);
577 extern Datum tideq(PG_FUNCTION_ARGS);
578 extern Datum tidne(PG_FUNCTION_ARGS);
579 extern Datum tidlt(PG_FUNCTION_ARGS);
580 extern Datum tidle(PG_FUNCTION_ARGS);
581 extern Datum tidgt(PG_FUNCTION_ARGS);
582 extern Datum tidge(PG_FUNCTION_ARGS);
583 extern Datum bttidcmp(PG_FUNCTION_ARGS);
584 extern Datum tidlarger(PG_FUNCTION_ARGS);
585 extern Datum tidsmaller(PG_FUNCTION_ARGS);
586 extern Datum currtid_byreloid(PG_FUNCTION_ARGS);
587 extern Datum currtid_byrelname(PG_FUNCTION_ARGS);
589 /* varchar.c */
590 extern Datum bpcharin(PG_FUNCTION_ARGS);
591 extern Datum bpcharout(PG_FUNCTION_ARGS);
592 extern Datum bpcharrecv(PG_FUNCTION_ARGS);
593 extern Datum bpcharsend(PG_FUNCTION_ARGS);
594 extern Datum bpchartypmodin(PG_FUNCTION_ARGS);
595 extern Datum bpchartypmodout(PG_FUNCTION_ARGS);
596 extern Datum bpchar(PG_FUNCTION_ARGS);
597 extern Datum char_bpchar(PG_FUNCTION_ARGS);
598 extern Datum name_bpchar(PG_FUNCTION_ARGS);
599 extern Datum bpchar_name(PG_FUNCTION_ARGS);
600 extern Datum bpchareq(PG_FUNCTION_ARGS);
601 extern Datum bpcharne(PG_FUNCTION_ARGS);
602 extern Datum bpcharlt(PG_FUNCTION_ARGS);
603 extern Datum bpcharle(PG_FUNCTION_ARGS);
604 extern Datum bpchargt(PG_FUNCTION_ARGS);
605 extern Datum bpcharge(PG_FUNCTION_ARGS);
606 extern Datum bpcharcmp(PG_FUNCTION_ARGS);
607 extern Datum bpchar_larger(PG_FUNCTION_ARGS);
608 extern Datum bpchar_smaller(PG_FUNCTION_ARGS);
609 extern Datum bpcharlen(PG_FUNCTION_ARGS);
610 extern Datum bpcharoctetlen(PG_FUNCTION_ARGS);
611 extern Datum hashbpchar(PG_FUNCTION_ARGS);
613 extern Datum varcharin(PG_FUNCTION_ARGS);
614 extern Datum varcharout(PG_FUNCTION_ARGS);
615 extern Datum varcharrecv(PG_FUNCTION_ARGS);
616 extern Datum varcharsend(PG_FUNCTION_ARGS);
617 extern Datum varchartypmodin(PG_FUNCTION_ARGS);
618 extern Datum varchartypmodout(PG_FUNCTION_ARGS);
619 extern Datum varchar(PG_FUNCTION_ARGS);
621 /* varlena.c */
622 extern Datum textin(PG_FUNCTION_ARGS);
623 extern Datum textout(PG_FUNCTION_ARGS);
624 extern Datum textrecv(PG_FUNCTION_ARGS);
625 extern Datum textsend(PG_FUNCTION_ARGS);
626 extern Datum textcat(PG_FUNCTION_ARGS);
627 extern Datum texteq(PG_FUNCTION_ARGS);
628 extern Datum textne(PG_FUNCTION_ARGS);
629 extern Datum text_lt(PG_FUNCTION_ARGS);
630 extern Datum text_le(PG_FUNCTION_ARGS);
631 extern Datum text_gt(PG_FUNCTION_ARGS);
632 extern Datum text_ge(PG_FUNCTION_ARGS);
633 extern Datum text_larger(PG_FUNCTION_ARGS);
634 extern Datum text_smaller(PG_FUNCTION_ARGS);
635 extern Datum text_pattern_eq(PG_FUNCTION_ARGS);
636 extern Datum text_pattern_ne(PG_FUNCTION_ARGS);
637 extern Datum text_pattern_lt(PG_FUNCTION_ARGS);
638 extern Datum text_pattern_le(PG_FUNCTION_ARGS);
639 extern Datum text_pattern_gt(PG_FUNCTION_ARGS);
640 extern Datum text_pattern_ge(PG_FUNCTION_ARGS);
641 extern Datum textlen(PG_FUNCTION_ARGS);
642 extern Datum textoctetlen(PG_FUNCTION_ARGS);
643 extern Datum textpos(PG_FUNCTION_ARGS);
644 extern Datum text_substr(PG_FUNCTION_ARGS);
645 extern Datum text_substr_no_len(PG_FUNCTION_ARGS);
646 extern Datum name_text(PG_FUNCTION_ARGS);
647 extern Datum text_name(PG_FUNCTION_ARGS);
648 extern int varstr_cmp(char *arg1, int len1, char *arg2, int len2);
649 extern List *textToQualifiedNameList(text *textval);
650 extern bool SplitIdentifierString(char *rawstring, char separator,
651 List **namelist);
652 extern Datum replace_text(PG_FUNCTION_ARGS);
653 extern text *replace_text_regexp(text *src_text, void *regexp,
654 text *replace_text, bool glob);
655 extern Datum split_text(PG_FUNCTION_ARGS);
656 extern Datum text_to_array(PG_FUNCTION_ARGS);
657 extern Datum array_to_text(PG_FUNCTION_ARGS);
658 extern Datum to_hex32(PG_FUNCTION_ARGS);
659 extern Datum to_hex64(PG_FUNCTION_ARGS);
660 extern Datum md5_text(PG_FUNCTION_ARGS);
661 extern Datum md5_bytea(PG_FUNCTION_ARGS);
663 extern Datum unknownin(PG_FUNCTION_ARGS);
664 extern Datum unknownout(PG_FUNCTION_ARGS);
665 extern Datum unknownrecv(PG_FUNCTION_ARGS);
666 extern Datum unknownsend(PG_FUNCTION_ARGS);
668 extern Datum byteain(PG_FUNCTION_ARGS);
669 extern Datum byteaout(PG_FUNCTION_ARGS);
670 extern Datum bytearecv(PG_FUNCTION_ARGS);
671 extern Datum byteasend(PG_FUNCTION_ARGS);
672 extern Datum byteaoctetlen(PG_FUNCTION_ARGS);
673 extern Datum byteaGetByte(PG_FUNCTION_ARGS);
674 extern Datum byteaGetBit(PG_FUNCTION_ARGS);
675 extern Datum byteaSetByte(PG_FUNCTION_ARGS);
676 extern Datum byteaSetBit(PG_FUNCTION_ARGS);
677 extern Datum binary_encode(PG_FUNCTION_ARGS);
678 extern Datum binary_decode(PG_FUNCTION_ARGS);
679 extern Datum byteaeq(PG_FUNCTION_ARGS);
680 extern Datum byteane(PG_FUNCTION_ARGS);
681 extern Datum bytealt(PG_FUNCTION_ARGS);
682 extern Datum byteale(PG_FUNCTION_ARGS);
683 extern Datum byteagt(PG_FUNCTION_ARGS);
684 extern Datum byteage(PG_FUNCTION_ARGS);
685 extern Datum byteacmp(PG_FUNCTION_ARGS);
686 extern Datum byteacat(PG_FUNCTION_ARGS);
687 extern Datum byteapos(PG_FUNCTION_ARGS);
688 extern Datum bytea_substr(PG_FUNCTION_ARGS);
689 extern Datum bytea_substr_no_len(PG_FUNCTION_ARGS);
690 extern Datum pg_column_size(PG_FUNCTION_ARGS);
692 /* version.c */
693 extern Datum pgsql_version(PG_FUNCTION_ARGS);
695 /* xid.c */
696 extern Datum xidin(PG_FUNCTION_ARGS);
697 extern Datum xidout(PG_FUNCTION_ARGS);
698 extern Datum xidrecv(PG_FUNCTION_ARGS);
699 extern Datum xidsend(PG_FUNCTION_ARGS);
700 extern Datum xideq(PG_FUNCTION_ARGS);
701 extern Datum xid_age(PG_FUNCTION_ARGS);
702 extern Datum cidin(PG_FUNCTION_ARGS);
703 extern Datum cidout(PG_FUNCTION_ARGS);
704 extern Datum cidrecv(PG_FUNCTION_ARGS);
705 extern Datum cidsend(PG_FUNCTION_ARGS);
706 extern Datum cideq(PG_FUNCTION_ARGS);
708 /* like.c */
709 extern Datum namelike(PG_FUNCTION_ARGS);
710 extern Datum namenlike(PG_FUNCTION_ARGS);
711 extern Datum nameiclike(PG_FUNCTION_ARGS);
712 extern Datum nameicnlike(PG_FUNCTION_ARGS);
713 extern Datum textlike(PG_FUNCTION_ARGS);
714 extern Datum textnlike(PG_FUNCTION_ARGS);
715 extern Datum texticlike(PG_FUNCTION_ARGS);
716 extern Datum texticnlike(PG_FUNCTION_ARGS);
717 extern Datum bytealike(PG_FUNCTION_ARGS);
718 extern Datum byteanlike(PG_FUNCTION_ARGS);
719 extern Datum like_escape(PG_FUNCTION_ARGS);
720 extern Datum like_escape_bytea(PG_FUNCTION_ARGS);
722 /* oracle_compat.c */
723 extern Datum lower(PG_FUNCTION_ARGS);
724 extern Datum upper(PG_FUNCTION_ARGS);
725 extern Datum initcap(PG_FUNCTION_ARGS);
726 extern Datum lpad(PG_FUNCTION_ARGS);
727 extern Datum rpad(PG_FUNCTION_ARGS);
728 extern Datum btrim(PG_FUNCTION_ARGS);
729 extern Datum btrim1(PG_FUNCTION_ARGS);
730 extern Datum byteatrim(PG_FUNCTION_ARGS);
731 extern Datum ltrim(PG_FUNCTION_ARGS);
732 extern Datum ltrim1(PG_FUNCTION_ARGS);
733 extern Datum rtrim(PG_FUNCTION_ARGS);
734 extern Datum rtrim1(PG_FUNCTION_ARGS);
735 extern Datum translate(PG_FUNCTION_ARGS);
736 extern Datum chr (PG_FUNCTION_ARGS);
737 extern Datum repeat(PG_FUNCTION_ARGS);
738 extern Datum ascii(PG_FUNCTION_ARGS);
740 /* inet_net_ntop.c */
741 extern char *inet_net_ntop(int af, const void *src, int bits,
742 char *dst, size_t size);
743 extern char *inet_cidr_ntop(int af, const void *src, int bits,
744 char *dst, size_t size);
746 /* inet_net_pton.c */
747 extern int inet_net_pton(int af, const char *src,
748 void *dst, size_t size);
750 /* network.c */
751 extern Datum inet_in(PG_FUNCTION_ARGS);
752 extern Datum inet_out(PG_FUNCTION_ARGS);
753 extern Datum inet_recv(PG_FUNCTION_ARGS);
754 extern Datum inet_send(PG_FUNCTION_ARGS);
755 extern Datum cidr_in(PG_FUNCTION_ARGS);
756 extern Datum cidr_out(PG_FUNCTION_ARGS);
757 extern Datum cidr_recv(PG_FUNCTION_ARGS);
758 extern Datum cidr_send(PG_FUNCTION_ARGS);
759 extern Datum network_cmp(PG_FUNCTION_ARGS);
760 extern Datum network_lt(PG_FUNCTION_ARGS);
761 extern Datum network_le(PG_FUNCTION_ARGS);
762 extern Datum network_eq(PG_FUNCTION_ARGS);
763 extern Datum network_ge(PG_FUNCTION_ARGS);
764 extern Datum network_gt(PG_FUNCTION_ARGS);
765 extern Datum network_ne(PG_FUNCTION_ARGS);
766 extern Datum hashinet(PG_FUNCTION_ARGS);
767 extern Datum network_sub(PG_FUNCTION_ARGS);
768 extern Datum network_subeq(PG_FUNCTION_ARGS);
769 extern Datum network_sup(PG_FUNCTION_ARGS);
770 extern Datum network_supeq(PG_FUNCTION_ARGS);
771 extern Datum network_network(PG_FUNCTION_ARGS);
772 extern Datum network_netmask(PG_FUNCTION_ARGS);
773 extern Datum network_hostmask(PG_FUNCTION_ARGS);
774 extern Datum network_masklen(PG_FUNCTION_ARGS);
775 extern Datum network_family(PG_FUNCTION_ARGS);
776 extern Datum network_broadcast(PG_FUNCTION_ARGS);
777 extern Datum network_host(PG_FUNCTION_ARGS);
778 extern Datum network_show(PG_FUNCTION_ARGS);
779 extern Datum inet_abbrev(PG_FUNCTION_ARGS);
780 extern Datum cidr_abbrev(PG_FUNCTION_ARGS);
781 extern double convert_network_to_scalar(Datum value, Oid typid);
782 extern Datum inet_to_cidr(PG_FUNCTION_ARGS);
783 extern Datum inet_set_masklen(PG_FUNCTION_ARGS);
784 extern Datum cidr_set_masklen(PG_FUNCTION_ARGS);
785 extern Datum network_scan_first(Datum in);
786 extern Datum network_scan_last(Datum in);
787 extern Datum inet_client_addr(PG_FUNCTION_ARGS);
788 extern Datum inet_client_port(PG_FUNCTION_ARGS);
789 extern Datum inet_server_addr(PG_FUNCTION_ARGS);
790 extern Datum inet_server_port(PG_FUNCTION_ARGS);
791 extern Datum inetnot(PG_FUNCTION_ARGS);
792 extern Datum inetand(PG_FUNCTION_ARGS);
793 extern Datum inetor(PG_FUNCTION_ARGS);
794 extern Datum inetpl(PG_FUNCTION_ARGS);
795 extern Datum inetmi_int8(PG_FUNCTION_ARGS);
796 extern Datum inetmi(PG_FUNCTION_ARGS);
797 extern void clean_ipv6_addr(int addr_family, char *addr);
799 /* mac.c */
800 extern Datum macaddr_in(PG_FUNCTION_ARGS);
801 extern Datum macaddr_out(PG_FUNCTION_ARGS);
802 extern Datum macaddr_recv(PG_FUNCTION_ARGS);
803 extern Datum macaddr_send(PG_FUNCTION_ARGS);
804 extern Datum macaddr_cmp(PG_FUNCTION_ARGS);
805 extern Datum macaddr_lt(PG_FUNCTION_ARGS);
806 extern Datum macaddr_le(PG_FUNCTION_ARGS);
807 extern Datum macaddr_eq(PG_FUNCTION_ARGS);
808 extern Datum macaddr_ge(PG_FUNCTION_ARGS);
809 extern Datum macaddr_gt(PG_FUNCTION_ARGS);
810 extern Datum macaddr_ne(PG_FUNCTION_ARGS);
811 extern Datum macaddr_trunc(PG_FUNCTION_ARGS);
812 extern Datum hashmacaddr(PG_FUNCTION_ARGS);
814 /* numeric.c */
815 extern Datum numeric_in(PG_FUNCTION_ARGS);
816 extern Datum numeric_out(PG_FUNCTION_ARGS);
817 extern Datum numeric_recv(PG_FUNCTION_ARGS);
818 extern Datum numeric_send(PG_FUNCTION_ARGS);
819 extern Datum numerictypmodin(PG_FUNCTION_ARGS);
820 extern Datum numerictypmodout(PG_FUNCTION_ARGS);
821 extern Datum numeric(PG_FUNCTION_ARGS);
822 extern Datum numeric_abs(PG_FUNCTION_ARGS);
823 extern Datum numeric_uminus(PG_FUNCTION_ARGS);
824 extern Datum numeric_uplus(PG_FUNCTION_ARGS);
825 extern Datum numeric_sign(PG_FUNCTION_ARGS);
826 extern Datum numeric_round(PG_FUNCTION_ARGS);
827 extern Datum numeric_trunc(PG_FUNCTION_ARGS);
828 extern Datum numeric_ceil(PG_FUNCTION_ARGS);
829 extern Datum numeric_floor(PG_FUNCTION_ARGS);
830 extern Datum numeric_cmp(PG_FUNCTION_ARGS);
831 extern Datum numeric_eq(PG_FUNCTION_ARGS);
832 extern Datum numeric_ne(PG_FUNCTION_ARGS);
833 extern Datum numeric_gt(PG_FUNCTION_ARGS);
834 extern Datum numeric_ge(PG_FUNCTION_ARGS);
835 extern Datum numeric_lt(PG_FUNCTION_ARGS);
836 extern Datum numeric_le(PG_FUNCTION_ARGS);
837 extern Datum numeric_add(PG_FUNCTION_ARGS);
838 extern Datum numeric_sub(PG_FUNCTION_ARGS);
839 extern Datum numeric_mul(PG_FUNCTION_ARGS);
840 extern Datum numeric_div(PG_FUNCTION_ARGS);
841 extern Datum numeric_mod(PG_FUNCTION_ARGS);
842 extern Datum numeric_inc(PG_FUNCTION_ARGS);
843 extern Datum numeric_smaller(PG_FUNCTION_ARGS);
844 extern Datum numeric_larger(PG_FUNCTION_ARGS);
845 extern Datum numeric_fac(PG_FUNCTION_ARGS);
846 extern Datum numeric_sqrt(PG_FUNCTION_ARGS);
847 extern Datum numeric_exp(PG_FUNCTION_ARGS);
848 extern Datum numeric_ln(PG_FUNCTION_ARGS);
849 extern Datum numeric_log(PG_FUNCTION_ARGS);
850 extern Datum numeric_power(PG_FUNCTION_ARGS);
851 extern Datum int4_numeric(PG_FUNCTION_ARGS);
852 extern Datum numeric_int4(PG_FUNCTION_ARGS);
853 extern Datum int8_numeric(PG_FUNCTION_ARGS);
854 extern Datum numeric_int8(PG_FUNCTION_ARGS);
855 extern Datum int2_numeric(PG_FUNCTION_ARGS);
856 extern Datum numeric_int2(PG_FUNCTION_ARGS);
857 extern Datum float8_numeric(PG_FUNCTION_ARGS);
858 extern Datum numeric_float8(PG_FUNCTION_ARGS);
859 extern Datum numeric_float8_no_overflow(PG_FUNCTION_ARGS);
860 extern Datum float4_numeric(PG_FUNCTION_ARGS);
861 extern Datum numeric_float4(PG_FUNCTION_ARGS);
862 extern Datum numeric_accum(PG_FUNCTION_ARGS);
863 extern Datum numeric_avg_accum(PG_FUNCTION_ARGS);
864 extern Datum int2_accum(PG_FUNCTION_ARGS);
865 extern Datum int4_accum(PG_FUNCTION_ARGS);
866 extern Datum int8_accum(PG_FUNCTION_ARGS);
867 extern Datum int8_avg_accum(PG_FUNCTION_ARGS);
868 extern Datum numeric_avg(PG_FUNCTION_ARGS);
869 extern Datum numeric_var_pop(PG_FUNCTION_ARGS);
870 extern Datum numeric_var_samp(PG_FUNCTION_ARGS);
871 extern Datum numeric_stddev_pop(PG_FUNCTION_ARGS);
872 extern Datum numeric_stddev_samp(PG_FUNCTION_ARGS);
873 extern Datum int2_sum(PG_FUNCTION_ARGS);
874 extern Datum int4_sum(PG_FUNCTION_ARGS);
875 extern Datum int8_sum(PG_FUNCTION_ARGS);
876 extern Datum int2_avg_accum(PG_FUNCTION_ARGS);
877 extern Datum int4_avg_accum(PG_FUNCTION_ARGS);
878 extern Datum int8_avg(PG_FUNCTION_ARGS);
879 extern Datum width_bucket_numeric(PG_FUNCTION_ARGS);
880 extern Datum hash_numeric(PG_FUNCTION_ARGS);
882 /* ri_triggers.c */
883 extern Datum RI_FKey_check_ins(PG_FUNCTION_ARGS);
884 extern Datum RI_FKey_check_upd(PG_FUNCTION_ARGS);
885 extern Datum RI_FKey_noaction_del(PG_FUNCTION_ARGS);
886 extern Datum RI_FKey_noaction_upd(PG_FUNCTION_ARGS);
887 extern Datum RI_FKey_cascade_del(PG_FUNCTION_ARGS);
888 extern Datum RI_FKey_cascade_upd(PG_FUNCTION_ARGS);
889 extern Datum RI_FKey_restrict_del(PG_FUNCTION_ARGS);
890 extern Datum RI_FKey_restrict_upd(PG_FUNCTION_ARGS);
891 extern Datum RI_FKey_setnull_del(PG_FUNCTION_ARGS);
892 extern Datum RI_FKey_setnull_upd(PG_FUNCTION_ARGS);
893 extern Datum RI_FKey_setdefault_del(PG_FUNCTION_ARGS);
894 extern Datum RI_FKey_setdefault_upd(PG_FUNCTION_ARGS);
896 /* encoding support functions */
897 extern Datum getdatabaseencoding(PG_FUNCTION_ARGS);
898 extern Datum database_character_set(PG_FUNCTION_ARGS);
899 extern Datum pg_client_encoding(PG_FUNCTION_ARGS);
900 extern Datum PG_encoding_to_char(PG_FUNCTION_ARGS);
901 extern Datum PG_char_to_encoding(PG_FUNCTION_ARGS);
902 extern Datum PG_character_set_name(PG_FUNCTION_ARGS);
903 extern Datum PG_character_set_id(PG_FUNCTION_ARGS);
904 extern Datum pg_convert(PG_FUNCTION_ARGS);
905 extern Datum pg_convert_to(PG_FUNCTION_ARGS);
906 extern Datum pg_convert_from(PG_FUNCTION_ARGS);
907 extern Datum length_in_encoding(PG_FUNCTION_ARGS);
909 /* format_type.c */
910 extern Datum format_type(PG_FUNCTION_ARGS);
911 extern char *format_type_be(Oid type_oid);
912 extern char *format_type_with_typemod(Oid type_oid, int32 typemod);
913 extern Datum oidvectortypes(PG_FUNCTION_ARGS);
914 extern int32 type_maximum_size(Oid type_oid, int32 typemod);
916 /* quote.c */
917 extern Datum quote_ident(PG_FUNCTION_ARGS);
918 extern Datum quote_literal(PG_FUNCTION_ARGS);
920 /* guc.c */
921 extern Datum show_config_by_name(PG_FUNCTION_ARGS);
922 extern Datum set_config_by_name(PG_FUNCTION_ARGS);
923 extern Datum show_all_settings(PG_FUNCTION_ARGS);
925 /* lockfuncs.c */
926 extern Datum pg_lock_status(PG_FUNCTION_ARGS);
927 extern Datum pg_advisory_lock_int8(PG_FUNCTION_ARGS);
928 extern Datum pg_advisory_lock_shared_int8(PG_FUNCTION_ARGS);
929 extern Datum pg_try_advisory_lock_int8(PG_FUNCTION_ARGS);
930 extern Datum pg_try_advisory_lock_shared_int8(PG_FUNCTION_ARGS);
931 extern Datum pg_advisory_unlock_int8(PG_FUNCTION_ARGS);
932 extern Datum pg_advisory_unlock_shared_int8(PG_FUNCTION_ARGS);
933 extern Datum pg_advisory_lock_int4(PG_FUNCTION_ARGS);
934 extern Datum pg_advisory_lock_shared_int4(PG_FUNCTION_ARGS);
935 extern Datum pg_try_advisory_lock_int4(PG_FUNCTION_ARGS);
936 extern Datum pg_try_advisory_lock_shared_int4(PG_FUNCTION_ARGS);
937 extern Datum pg_advisory_unlock_int4(PG_FUNCTION_ARGS);
938 extern Datum pg_advisory_unlock_shared_int4(PG_FUNCTION_ARGS);
939 extern Datum pg_advisory_unlock_all(PG_FUNCTION_ARGS);
941 /* txid.c */
942 extern Datum txid_snapshot_in(PG_FUNCTION_ARGS);
943 extern Datum txid_snapshot_out(PG_FUNCTION_ARGS);
944 extern Datum txid_snapshot_recv(PG_FUNCTION_ARGS);
945 extern Datum txid_snapshot_send(PG_FUNCTION_ARGS);
946 extern Datum txid_current(PG_FUNCTION_ARGS);
947 extern Datum txid_current_snapshot(PG_FUNCTION_ARGS);
948 extern Datum txid_snapshot_xmin(PG_FUNCTION_ARGS);
949 extern Datum txid_snapshot_xmax(PG_FUNCTION_ARGS);
950 extern Datum txid_snapshot_xip(PG_FUNCTION_ARGS);
951 extern Datum txid_visible_in_snapshot(PG_FUNCTION_ARGS);
953 /* uuid.c */
954 extern Datum uuid_in(PG_FUNCTION_ARGS);
955 extern Datum uuid_out(PG_FUNCTION_ARGS);
956 extern Datum uuid_send(PG_FUNCTION_ARGS);
957 extern Datum uuid_recv(PG_FUNCTION_ARGS);
958 extern Datum uuid_lt(PG_FUNCTION_ARGS);
959 extern Datum uuid_le(PG_FUNCTION_ARGS);
960 extern Datum uuid_eq(PG_FUNCTION_ARGS);
961 extern Datum uuid_ge(PG_FUNCTION_ARGS);
962 extern Datum uuid_gt(PG_FUNCTION_ARGS);
963 extern Datum uuid_ne(PG_FUNCTION_ARGS);
964 extern Datum uuid_cmp(PG_FUNCTION_ARGS);
965 extern Datum uuid_hash(PG_FUNCTION_ARGS);
967 /* access/transam/twophase.c */
968 extern Datum pg_prepared_xact(PG_FUNCTION_ARGS);
970 /* commands/prepare.c */
971 extern Datum pg_prepared_statement(PG_FUNCTION_ARGS);
973 /* utils/mmgr/portalmem.c */
974 extern Datum pg_cursor(PG_FUNCTION_ARGS);
976 #endif /* BUILTINS_H */