mirror of
https://github.com/postgres/postgres.git
synced 2025-07-07 00:36:50 +03:00
Numeric error suppression in jsonpath
Add support of numeric error suppression to jsonpath as it's required by standard. This commit doesn't use PG_TRY()/PG_CATCH() in order to implement that. Instead, it provides internal versions of numeric functions used, which support error suppression. Discussion: https://postgr.es/m/fcc6fc6a-b497-f39a-923d-aa34d0c588e8%402ndQuadrant.com Author: Alexander Korotkov, Nikita Glukhov Reviewed-by: Tomas Vondra
This commit is contained in:
@ -61,4 +61,16 @@ int32 numeric_maximum_size(int32 typmod);
|
||||
extern char *numeric_out_sci(Numeric num, int scale);
|
||||
extern char *numeric_normalize(Numeric num);
|
||||
|
||||
extern Numeric numeric_add_opt_error(Numeric num1, Numeric num2,
|
||||
bool *have_error);
|
||||
extern Numeric numeric_sub_opt_error(Numeric num1, Numeric num2,
|
||||
bool *have_error);
|
||||
extern Numeric numeric_mul_opt_error(Numeric num1, Numeric num2,
|
||||
bool *have_error);
|
||||
extern Numeric numeric_div_opt_error(Numeric num1, Numeric num2,
|
||||
bool *have_error);
|
||||
extern Numeric numeric_mod_opt_error(Numeric num1, Numeric num2,
|
||||
bool *have_error);
|
||||
extern int32 numeric_int4_opt_error(Numeric num, bool *error);
|
||||
|
||||
#endif /* _PG_NUMERIC_H_ */
|
||||
|
Reference in New Issue
Block a user