{"Entry":{"collection":"func","key":"jsonb-strip-nulls","name":"jsonb_strip_nulls","aliases":[],"metadata":{"changed_in":["18"],"changes":[{"descriptions_changed":false,"doc_overhaul":false,"from":"9.4","group_changed":null,"signatures":{"added":[],"removed":[]},"status":"added","to":"9.5"},{"descriptions_changed":false,"doc_overhaul":true,"from":"12","group_changed":null,"signatures":{"added":[],"removed":[]},"status":"changed","to":"13"},{"descriptions_changed":true,"doc_overhaul":false,"from":"17","group_changed":null,"signatures":{"added":["jsonb_strip_nulls ( target jsonb [,strip_in_arrays boolean ] ) → jsonb"],"removed":["jsonb_strip_nulls ( jsonb ) → jsonb"]},"status":"changed","to":"18"}],"content_hash":"a35db933d9f158e3d530a8a9f59e34d2107e5571561510885b9154705d355770","first_version":"9.5","group":"json","group_label":"Json Functions And Operators","groups":["json"],"imported_at":"2026-09-27T17:57:28.8382+08:00","last_version":"20","name":"jsonb_strip_nulls","name_key":"jsonb_strip_nulls","position":16054,"present_in":["9.5","9.6","10","11","12","13","14","15","16","17","18","19","20"],"signature":"jsonb_strip_nulls ( target jsonb [,strip_in_arrays boolean ] ) → jsonb","signature_count":1,"slug":"jsonb-strip-nulls","source_rev":"b7bd9cda","summary":"Deletes all object fields that have null values from the given JSON value, recursively.","summary_zh":""}},"Definition":{"Collection":"func","Key":"jsonb-strip-nulls","SourceDatabase":"center","Version":"18","SourceTable":"func","SourceKey":"jsonb-strip-nulls","SourceRevision":"b7bd9cda","Facts":{"description":"Deletes all object fields that have null values from the given JSON value, recursively. If strip_in_arrays is true (the default is false), null array elements are also stripped. Otherwise they are not stripped. Bare null values are never stripped.","description_html":"Deletes all object fields that have null values from the given JSON value, recursively. If \u003cem class=\"parameter\"\u003e\u003ccode\u003estrip_in_arrays\u003c/code\u003e\u003c/em\u003e is true (the default is false), null array elements are also stripped. Otherwise they are not stripped. Bare null values are never stripped.","description_zh":"","description_zh_html":"","doc":{"anchor":"FUNCTIONS-JSON-PROCESSING-TABLE","file":"functions-json.html","slug":"18"},"group":"json","group_label":"Json Functions And Operators","lang":"en","layout":"table-new","pages":["functions-json.html"],"prose_only":false,"signatures":[{"description":"Deletes all object fields that have null values from the given JSON value, recursively. If strip_in_arrays is true (the default is false), null array elements are also stripped. Otherwise they are not stripped. Bare null values are never stripped.","description_html":"Deletes all object fields that have null values from the given JSON value, recursively. If \u003cem class=\"parameter\"\u003e\u003ccode\u003estrip_in_arrays\u003c/code\u003e\u003c/em\u003e is true (the default is false), null array elements are also stripped. Otherwise they are not stripped. Bare null values are never stripped.","description_zh":"","description_zh_html":"","examples":[{"expr":"json_strip_nulls('[{\"f1\":1, \"f2\":null}, 2, null, 3]')","result":"[{\"f1\":1},2,null,3]"},{"expr":"jsonb_strip_nulls('[1,2,null,3,4]', true)","result":"[1,2,3,4]"}],"html":"\u003ccode class=\"function\"\u003ejsonb_strip_nulls\u003c/code\u003e ( \u003cem class=\"parameter\"\u003e\u003ccode\u003etarget\u003c/code\u003e\u003c/em\u003e \u003ccode class=\"type\"\u003ejsonb\u003c/code\u003e [\u003cspan class=\"optional\"\u003e,\u003cem class=\"parameter\"\u003e\u003ccode\u003estrip_in_arrays\u003c/code\u003e\u003c/em\u003e \u003ccode class=\"type\"\u003eboolean\u003c/code\u003e\u003c/span\u003e ] ) → \u003ccode class=\"returnvalue\"\u003ejsonb\u003c/code\u003e","returns":"jsonb","text":"jsonb_strip_nulls ( target jsonb [,strip_in_arrays boolean ] ) → jsonb","zh_from":""}],"zh_from":""},"ManualEvidence":{"doc":{"anchor":"FUNCTIONS-JSON-PROCESSING-TABLE","file":"functions-json.html","slug":"18"}},"MeasuredEvidence":{}},"Text":{"Collection":"func","Key":"jsonb-strip-nulls","SourceDatabase":"pgweb","Version":"18","Locale":"zh-Hans","Title":"jsonb_strip_nulls","Summary":"递归地删除给定 JSON 值中所有值为 null 的对象字段。如果 strip_in_arrays 为 true（默认值为 false），那么数组中的 null 元素也会被删除；否则不会删除。裸露的 null 值永远不会被删除。","BodyHTML":"递归地删除给定 JSON 值中所有值为 null 的对象字段。如果 \u003cem\u003e\u003ccode\u003estrip_in_arrays\u003c/code\u003e\u003c/em\u003e 为 true（默认值为 false），那么数组中的 null 元素也会被删除；否则不会删除。裸露的 null 值永远不会被删除。\u003cpre\u003ejsonb_strip_nulls ( target jsonb [,strip_in_arrays boolean ] ) → jsonb\u003c/pre\u003e递归地删除给定 JSON 值中所有值为 null 的对象字段。如果 \u003cem\u003e\u003ccode\u003estrip_in_arrays\u003c/code\u003e\u003c/em\u003e 为 true（默认值为 false），那么数组中的 null 元素也会被删除；否则不会删除。裸露的 null 值永远不会被删除。","SourceRevision":"1b5ca64c","ContentHash":"e0a5446fb49a13004b6caaa894bb351708941905d3a85f6a9e5cd9a7118bdb77","Payload":{"description_zh":"递归地删除给定 JSON 值中所有值为 null 的对象字段。如果 strip_in_arrays 为 true（默认值为 false），那么数组中的 null 元素也会被删除；否则不会删除。裸露的 null 值永远不会被删除。","description_zh_html":"递归地删除给定 JSON 值中所有值为 null 的对象字段。如果 \u003cem class=\"parameter\"\u003e\u003ccode\u003estrip_in_arrays\u003c/code\u003e\u003c/em\u003e 为 true（默认值为 false），那么数组中的 null 元素也会被删除；否则不会删除。裸露的 null 值永远不会被删除。","signatures":[{"description_zh":"递归地删除给定 JSON 值中所有值为 null 的对象字段。如果 strip_in_arrays 为 true（默认值为 false），那么数组中的 null 元素也会被删除；否则不会删除。裸露的 null 值永远不会被删除。","description_zh_html":"递归地删除给定 JSON 值中所有值为 null 的对象字段。如果 \u003cem class=\"parameter\"\u003e\u003ccode\u003estrip_in_arrays\u003c/code\u003e\u003c/em\u003e 为 true（默认值为 false），那么数组中的 null 元素也会被删除；否则不会删除。裸露的 null 值永远不会被删除。","returns":"jsonb","text":"jsonb_strip_nulls ( target jsonb [,strip_in_arrays boolean ] ) → jsonb","zh_from":"doc"}],"zh_from":"doc"}},"RequestedLocale":"zh-Hans","Fallback":false,"Versions":["10","11","12","13","14","15","16","17","18","19","20","9.5","9.6"],"Locales":["en","zh-Hans"],"Signatures":[{"Version":"18","Ordinal":0,"Hash":"527fbe251071c50da96e0c72a6b705a746cd272335ab387ba885eeb76618d6cf","Text":"jsonb_strip_nulls ( target jsonb [,strip_in_arrays boolean ] ) → jsonb","Returns":"jsonb","Payload":{"description":"Deletes all object fields that have null values from the given JSON value, recursively. If strip_in_arrays is true (the default is false), null array elements are also stripped. Otherwise they are not stripped. Bare null values are never stripped.","description_html":"Deletes all object fields that have null values from the given JSON value, recursively. If \u003cem class=\"parameter\"\u003e\u003ccode\u003estrip_in_arrays\u003c/code\u003e\u003c/em\u003e is true (the default is false), null array elements are also stripped. Otherwise they are not stripped. Bare null values are never stripped.","description_zh":"","description_zh_html":"","examples":[{"expr":"json_strip_nulls('[{\"f1\":1, \"f2\":null}, 2, null, 3]')","result":"[{\"f1\":1},2,null,3]"},{"expr":"jsonb_strip_nulls('[1,2,null,3,4]', true)","result":"[1,2,3,4]"}],"html":"\u003ccode class=\"function\"\u003ejsonb_strip_nulls\u003c/code\u003e ( \u003cem class=\"parameter\"\u003e\u003ccode\u003etarget\u003c/code\u003e\u003c/em\u003e \u003ccode class=\"type\"\u003ejsonb\u003c/code\u003e [\u003cspan class=\"optional\"\u003e,\u003cem class=\"parameter\"\u003e\u003ccode\u003estrip_in_arrays\u003c/code\u003e\u003c/em\u003e \u003ccode class=\"type\"\u003eboolean\u003c/code\u003e\u003c/span\u003e ] ) → \u003ccode class=\"returnvalue\"\u003ejsonb\u003c/code\u003e","returns":"jsonb","text":"jsonb_strip_nulls ( target jsonb [,strip_in_arrays boolean ] ) → jsonb","zh_from":""}}],"Spellings":null,"SQLState":null,"Evidence":null}
