forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit03734a7
committed
Add more SQL/JSON constructor functions
This Patch introduces three SQL standard JSON functions:JSON()JSON_SCALAR()JSON_SERIALIZE()JSON() produces json values from text, bytea, json or jsonb values,and has facilitites for handling duplicate keys.JSON_SCALAR() produces a json value from any scalar sql value,including json and jsonb.JSON_SERIALIZE() produces text or bytea from input which containisor represents json or jsonb;For the most part these functions don't add any significant newcapabilities, but they will be of use to users wanting standardcompliant JSON handling.Catversion bumped as this changes ruleutils.c.Author: Nikita Glukhov <n.gluhov@postgrespro.ru>Author: Teodor Sigaev <teodor@sigaev.ru>Author: Oleg Bartunov <obartunov@gmail.com>Author: Alexander Korotkov <aekorotkov@gmail.com>Author: Andrew Dunstan <andrew@dunslane.net>Author: Amit Langote <amitlangote09@gmail.com>Reviewers have included (in no particular order) Andres Freund, AlexanderKorotkov, Pavel Stehule, Andrew Alsup, Erik Rijkers, Zihong Yu,Himanshu Upadhyaya, Daniel Gustafsson, Justin Pryzby, Álvaro Herrera,Peter EisentrautDiscussion:https://postgr.es/m/cd0bb935-0158-78a7-08b5-904886deac4b@postgrespro.ruDiscussion:https://postgr.es/m/20220616233130.rparivafipt6doj3@alap3.anarazel.deDiscussion:https://postgr.es/m/abd9b83b-aa66-f230-3d6d-734817f0995d%40postgresql.orgDiscussion:https://postgr.es/m/CA+HiwqE4XTdfb1nW=Ojoy_tQSRhYt-q_kb6i5d4xcKyrLC1Nbg@mail.gmail.com1 parent254ac5a commit03734a7
File tree
22 files changed
+1397
-42
lines changed- doc/src/sgml
- src
- backend
- executor
- nodes
- parser
- utils/adt
- include
- catalog
- nodes
- parser
- utils
- interfaces/ecpg/test
- expected
- sql
- test/regress
- expected
- sql
- tools/pgindent
22 files changed
+1397
-42
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16001 | 16001 | | |
16002 | 16002 | | |
16003 | 16003 | | |
| 16004 | + | |
| 16005 | + | |
| 16006 | + | |
| 16007 | + | |
| 16008 | + | |
| 16009 | + | |
| 16010 | + | |
| 16011 | + | |
| 16012 | + | |
| 16013 | + | |
| 16014 | + | |
| 16015 | + | |
| 16016 | + | |
| 16017 | + | |
| 16018 | + | |
| 16019 | + | |
| 16020 | + | |
| 16021 | + | |
| 16022 | + | |
| 16023 | + | |
| 16024 | + | |
| 16025 | + | |
| 16026 | + | |
| 16027 | + | |
| 16028 | + | |
| 16029 | + | |
| 16030 | + | |
| 16031 | + | |
| 16032 | + | |
| 16033 | + | |
| 16034 | + | |
| 16035 | + | |
| 16036 | + | |
| 16037 | + | |
| 16038 | + | |
| 16039 | + | |
| 16040 | + | |
| 16041 | + | |
| 16042 | + | |
| 16043 | + | |
| 16044 | + | |
| 16045 | + | |
| 16046 | + | |
| 16047 | + | |
| 16048 | + | |
| 16049 | + | |
| 16050 | + | |
| 16051 | + | |
| 16052 | + | |
| 16053 | + | |
| 16054 | + | |
| 16055 | + | |
| 16056 | + | |
| 16057 | + | |
| 16058 | + | |
| 16059 | + | |
| 16060 | + | |
| 16061 | + | |
| 16062 | + | |
| 16063 | + | |
| 16064 | + | |
| 16065 | + | |
| 16066 | + | |
| 16067 | + | |
| 16068 | + | |
| 16069 | + | |
16004 | 16070 | | |
16005 | 16071 | | |
16006 | 16072 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
| 51 | + | |
51 | 52 | | |
52 | 53 | | |
53 | 54 | | |
| |||
2311 | 2312 | | |
2312 | 2313 | | |
2313 | 2314 | | |
| 2315 | + | |
| 2316 | + | |
| 2317 | + | |
| 2318 | + | |
| 2319 | + | |
| 2320 | + | |
2314 | 2321 | | |
2315 | 2322 | | |
2316 | 2323 | | |
| |||
2349 | 2356 | | |
2350 | 2357 | | |
2351 | 2358 | | |
| 2359 | + | |
| 2360 | + | |
| 2361 | + | |
| 2362 | + | |
| 2363 | + | |
| 2364 | + | |
| 2365 | + | |
| 2366 | + | |
| 2367 | + | |
| 2368 | + | |
| 2369 | + | |
| 2370 | + | |
| 2371 | + | |
| 2372 | + | |
| 2373 | + | |
| 2374 | + | |
| 2375 | + | |
| 2376 | + | |
| 2377 | + | |
| 2378 | + | |
| 2379 | + | |
| 2380 | + | |
| 2381 | + | |
2352 | 2382 | | |
2353 | 2383 | | |
2354 | 2384 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4002 | 4002 | | |
4003 | 4003 | | |
4004 | 4004 | | |
| 4005 | + | |
| 4006 | + | |
| 4007 | + | |
| 4008 | + | |
| 4009 | + | |
| 4010 | + | |
| 4011 | + | |
| 4012 | + | |
| 4013 | + | |
| 4014 | + | |
| 4015 | + | |
| 4016 | + | |
| 4017 | + | |
| 4018 | + | |
| 4019 | + | |
| 4020 | + | |
| 4021 | + | |
| 4022 | + | |
| 4023 | + | |
| 4024 | + | |
| 4025 | + | |
| 4026 | + | |
| 4027 | + | |
| 4028 | + | |
| 4029 | + | |
| 4030 | + | |
| 4031 | + | |
| 4032 | + | |
| 4033 | + | |
| 4034 | + | |
| 4035 | + | |
| 4036 | + | |
| 4037 | + | |
| 4038 | + | |
| 4039 | + | |
| 4040 | + | |
| 4041 | + | |
| 4042 | + | |
| 4043 | + | |
| 4044 | + | |
| 4045 | + | |
4005 | 4046 | | |
4006 | 4047 | | |
4007 | 4048 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3899 | 3899 | | |
3900 | 3900 | | |
3901 | 3901 | | |
| 3902 | + | |
| 3903 | + | |
| 3904 | + | |
| 3905 | + | |
| 3906 | + | |
| 3907 | + | |
| 3908 | + | |
| 3909 | + | |
| 3910 | + | |
| 3911 | + | |
| 3912 | + | |
| 3913 | + | |
| 3914 | + | |
| 3915 | + | |
| 3916 | + | |
| 3917 | + | |
| 3918 | + | |
| 3919 | + | |
| 3920 | + | |
| 3921 | + | |
| 3922 | + | |
| 3923 | + | |
| 3924 | + | |
| 3925 | + | |
| 3926 | + | |
| 3927 | + | |
| 3928 | + | |
| 3929 | + | |
| 3930 | + | |
| 3931 | + | |
3902 | 3932 | | |
3903 | 3933 | | |
3904 | 3934 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
566 | 566 | | |
567 | 567 | | |
568 | 568 | | |
569 | | - | |
| 569 | + | |
570 | 570 | | |
571 | 571 | | |
572 | 572 | | |
| |||
723 | 723 | | |
724 | 724 | | |
725 | 725 | | |
| 726 | + | |
726 | 727 | | |
727 | 728 | | |
728 | 729 | | |
| |||
13990 | 13991 | | |
13991 | 13992 | | |
13992 | 13993 | | |
| 13994 | + | |
13993 | 13995 | | |
13994 | 13996 | | |
13995 | 13997 | | |
| |||
14008 | 14010 | | |
14009 | 14011 | | |
14010 | 14012 | | |
| 14013 | + | |
14011 | 14014 | | |
14012 | 14015 | | |
14013 | 14016 | | |
| |||
14376 | 14379 | | |
14377 | 14380 | | |
14378 | 14381 | | |
| 14382 | + | |
| 14383 | + | |
| 14384 | + | |
| 14385 | + | |
| 14386 | + | |
| 14387 | + | |
| 14388 | + | |
14379 | 14389 | | |
14380 | 14390 | | |
14381 | 14391 | | |
| |||
15634 | 15644 | | |
15635 | 15645 | | |
15636 | 15646 | | |
15637 | | - | |
| 15647 | + | |
| 15648 | + | |
| 15649 | + | |
| 15650 | + | |
| 15651 | + | |
| 15652 | + | |
| 15653 | + | |
| 15654 | + | |
| 15655 | + | |
| 15656 | + | |
| 15657 | + | |
| 15658 | + | |
| 15659 | + | |
| 15660 | + | |
| 15661 | + | |
| 15662 | + | |
| 15663 | + | |
| 15664 | + | |
| 15665 | + | |
| 15666 | + | |
| 15667 | + | |
| 15668 | + | |
| 15669 | + | |
| 15670 | + | |
| 15671 | + | |
| 15672 | + | |
| 15673 | + | |
| 15674 | + | |
| 15675 | + | |
| 15676 | + | |
15638 | 15677 | | |
15639 | 15678 | | |
15640 | 15679 | | |
| |||
17075 | 17114 | | |
17076 | 17115 | | |
17077 | 17116 | | |
17078 | | - | |
17079 | 17117 | | |
17080 | 17118 | | |
17081 | 17119 | | |
| |||
17290 | 17328 | | |
17291 | 17329 | | |
17292 | 17330 | | |
| 17331 | + | |
17293 | 17332 | | |
17294 | 17333 | | |
17295 | 17334 | | |
17296 | 17335 | | |
| 17336 | + | |
| 17337 | + | |
17297 | 17338 | | |
17298 | 17339 | | |
17299 | 17340 | | |
| |||
17654 | 17695 | | |
17655 | 17696 | | |
17656 | 17697 | | |
| 17698 | + | |
| 17699 | + | |
17657 | 17700 | | |
17658 | 17701 | | |
17659 | 17702 | | |
| |||
0 commit comments
Comments
(0)