{"Entry":{"collection":"func","key":"xml-is-well-formed-document","name":"xml_is_well_formed_document","aliases":[],"metadata":{"changed_in":[],"changes":[{"descriptions_changed":false,"doc_overhaul":false,"from":"9.0","group_changed":null,"signatures":{"added":[],"removed":[]},"status":"added","to":"9.1"},{"descriptions_changed":false,"doc_overhaul":true,"from":"12","group_changed":null,"signatures":{"added":[],"removed":[]},"status":"changed","to":"13"}],"content_hash":"e577b63f9901400c40df2f1ae6b9fec7352bc0b4cf447a8da1a3180018a6e3a4","derived_content_hash":"6724e5516d87d12c12aef4c5e52b03775d3dec07952afb3f53959327d24eff36","documentation_refresh":{"batch":"20261113","original_source_rev":"wiki-repair-20261023:cc5db093f4bcbc2d9600246057a53762a9a08ce864daa04a2bca2af5034692b5","versions":{"14":"14.25","15":"15.20","16":"16.16","17":"17.12","18":"18.7","19":"19rc2"}},"first_version":"9.1","group":"xml","group_label":"Xml Functions","groups":["xml"],"imported_at":"2026-09-14T21:49:48.767106+08:00","last_version":"20","name":"xml_is_well_formed_document","name_key":"xml_is_well_formed_document","position":15016,"present_in":["9.1","9.2","9.3","9.4","9.5","9.6","10","11","12","13","14","15","16","17","18","19","20"],"repair_provenance":{"original_source_revision":"2026-09-14T13:14:25.684213+00:00@99e6866c","receipt_sha256":"e51ef8dc679c9100ae5138b53193ac668d9a517c11a2420e260560984b7e175d","repair":"wiki-repair-20261023"},"signature":"xml_is_well_formed_document ( text ) → boolean","signature_count":1,"slug":"xml-is-well-formed-document","source_rev":"wiki-repair-20261023:cc5db093f4bcbc2d9600246057a53762a9a08ce864daa04a2bca2af5034692b5","summary":"These functions check whether a text string represents well-formed XML, returning a Boolean result.","summary_zh":""}},"Definition":{"Collection":"func","Key":"xml-is-well-formed-document","SourceDatabase":"center","Version":"18","SourceTable":"func","SourceKey":"xml-is-well-formed-document","SourceRevision":"wiki-repair-20261023:cc5db093f4bcbc2d9600246057a53762a9a08ce864daa04a2bca2af5034692b5","Facts":{"description":"These functions check whether a text string represents well-formed XML, returning a Boolean result. xml_is_well_formed_document checks for a well-formed document, while xml_is_well_formed_content checks for well-formed content. xml_is_well_formed does the former if the xmloption configuration parameter is set to DOCUMENT, or the latter if it is set to CONTENT. This means that xml_is_well_formed is useful for seeing whether a simple cast to type xml will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of XMLPARSE will succeed.","description_html":"These functions check whether a \u003ccode class=\"type\"\u003etext\u003c/code\u003e string represents well-formed XML, returning a Boolean result. \u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e checks for a well-formed document, while \u003ccode class=\"function\"\u003exml_is_well_formed_content\u003c/code\u003e checks for well-formed content. \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e does the former if the \u003ca href=\"/docs/18/runtime-config-client.html#GUC-XMLOPTION\"\u003exmloption\u003c/a\u003e configuration parameter is set to \u003ccode class=\"literal\"\u003eDOCUMENT\u003c/code\u003e, or the latter if it is set to \u003ccode class=\"literal\"\u003eCONTENT\u003c/code\u003e. This means that \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e is useful for seeing whether a simple cast to type \u003ccode class=\"type\"\u003exml\u003c/code\u003e will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of \u003ccode class=\"function\"\u003eXMLPARSE\u003c/code\u003e will succeed.","description_zh":"这些函数检查一个 text 串是不是一个良构的 XML，返回一个布尔结果。xml_is_well_formed_document 检查一个良构的文档，而 xml_is_well_formed_content 检查良构的内容。如果 xmloption 配置参数被设置为 DOCUMENT，xml_is_well_formed 会做第一个函数的工作；如果配置参数被设置为 CONTENT，xml_is_well_formed 会做第二个函数的工作。这意味着 xml_is_well_formed 对于检查一个到类型 xml 的简单类型转换是否会成功非常有用，而其他两个函数对于检查 XMLPARSE 的对应变体是否会成功有用。","description_zh_html":"这些函数检查一个 \u003ccode class=\"type\"\u003etext\u003c/code\u003e 串是不是一个良构的 XML，返回一个布尔结果。\u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e 检查一个良构的文档，而 \u003ccode class=\"function\"\u003exml_is_well_formed_content\u003c/code\u003e 检查良构的内容。如果 \u003ca href=\"/docs/18/runtime-config-client.html#GUC-XMLOPTION\"\u003exmloption\u003c/a\u003e 配置参数被设置为 \u003ccode class=\"literal\"\u003eDOCUMENT\u003c/code\u003e，\u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 会做第一个函数的工作；如果配置参数被设置为 \u003ccode class=\"literal\"\u003eCONTENT\u003c/code\u003e，\u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 会做第二个函数的工作。这意味着 \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 对于检查一个到类型 \u003ccode class=\"type\"\u003exml\u003c/code\u003e 的简单类型转换是否会成功非常有用，而其他两个函数对于检查 \u003ccode class=\"function\"\u003eXMLPARSE\u003c/code\u003e 的对应变体是否会成功有用。","doc":{"anchor":"XML-IS-WELL-FORMED","file":"functions-xml.html","sha256":"01aeb9b85a44b934664d02e73f09eba80ac8da243706dd1ea2b4943d6cf43a31","slug":"18"},"documentation_revision":{"inputs":[{"file":"functions-xml.html","kind":"same-version-reviewed-manual","locale":"en","sha256":"01aeb9b85a44b934664d02e73f09eba80ac8da243706dd1ea2b4943d6cf43a31","version":"18.7"},{"file":"functions-xml.html","kind":"same-version-reviewed-manual","locale":"zh-Hans","sha256":"7f81f95d894b56436ba5c9f248999c6f79a15eff2f8e02803e9578894005ba44","version":"18.7"}],"release":"18.7","runtime_remeasured":false,"source_revision":"pgdoc:b9f0e7232f60f380d642ac9b99226606c254b552"},"group":"xml","group_label":"XML 函数","lang":"en","layout":"table-new","pages":["functions-xml.html"],"prose_only":false,"signatures":[{"description":"These functions check whether a text string represents well-formed XML, returning a Boolean result. xml_is_well_formed_document checks for a well-formed document, while xml_is_well_formed_content checks for well-formed content. xml_is_well_formed does the former if the xmloption configuration parameter is set to DOCUMENT, or the latter if it is set to CONTENT. This means that xml_is_well_formed is useful for seeing whether a simple cast to type xml will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of XMLPARSE will succeed.","description_html":"These functions check whether a \u003ccode class=\"type\"\u003etext\u003c/code\u003e string represents well-formed XML, returning a Boolean result. \u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e checks for a well-formed document, while \u003ccode class=\"function\"\u003exml_is_well_formed_content\u003c/code\u003e checks for well-formed content. \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e does the former if the \u003ca href=\"/docs/18/runtime-config-client.html#GUC-XMLOPTION\"\u003exmloption\u003c/a\u003e configuration parameter is set to \u003ccode class=\"literal\"\u003eDOCUMENT\u003c/code\u003e, or the latter if it is set to \u003ccode class=\"literal\"\u003eCONTENT\u003c/code\u003e. This means that \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e is useful for seeing whether a simple cast to type \u003ccode class=\"type\"\u003exml\u003c/code\u003e will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of \u003ccode class=\"function\"\u003eXMLPARSE\u003c/code\u003e will succeed.","description_zh":"这些函数检查一个 text 串是不是一个良构的 XML，返回一个布尔结果。xml_is_well_formed_document 检查一个良构的文档，而 xml_is_well_formed_content 检查良构的内容。如果 xmloption 配置参数被设置为 DOCUMENT，xml_is_well_formed 会做第一个函数的工作；如果配置参数被设置为 CONTENT，xml_is_well_formed 会做第二个函数的工作。这意味着 xml_is_well_formed 对于检查一个到类型 xml 的简单类型转换是否会成功非常有用，而其他两个函数对于检查 XMLPARSE 的对应变体是否会成功有用。","description_zh_html":"这些函数检查一个 \u003ccode class=\"type\"\u003etext\u003c/code\u003e 串是不是一个良构的 XML，返回一个布尔结果。\u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e 检查一个良构的文档，而 \u003ccode class=\"function\"\u003exml_is_well_formed_content\u003c/code\u003e 检查良构的内容。如果 \u003ca href=\"/docs/18/runtime-config-client.html#GUC-XMLOPTION\"\u003exmloption\u003c/a\u003e 配置参数被设置为 \u003ccode class=\"literal\"\u003eDOCUMENT\u003c/code\u003e，\u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 会做第一个函数的工作；如果配置参数被设置为 \u003ccode class=\"literal\"\u003eCONTENT\u003c/code\u003e，\u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 会做第二个函数的工作。这意味着 \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 对于检查一个到类型 \u003ccode class=\"type\"\u003exml\u003c/code\u003e 的简单类型转换是否会成功非常有用，而其他两个函数对于检查 \u003ccode class=\"function\"\u003eXMLPARSE\u003c/code\u003e 的对应变体是否会成功有用。","examples":[],"html":"\u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e ( \u003ccode class=\"type\"\u003etext\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003eboolean\u003c/code\u003e","returns":"boolean","text":"xml_is_well_formed_document ( text ) → boolean","zh_from":"same-version-manual"}],"translation_provenance":{"inputs":[{"kind":"current-pgdoc-translation","path":"/Users/vonng/pgsty/pgdoc/zh/18/html/functions-xml.html","sha256":"fecb5d8486a96d59e4b5808eeaa769d216ab3be80602eb0c73702f28dd37388c"}],"kind":"same-version-pgdoc","locale":"zh-Hans","source_revision":"b1b500221dbe5437cfca004d6b04d3f6e422765d","version":"18"},"zh_from":"same-version-manual"},"ManualEvidence":{"doc":{"anchor":"XML-IS-WELL-FORMED","file":"functions-xml.html","sha256":"01aeb9b85a44b934664d02e73f09eba80ac8da243706dd1ea2b4943d6cf43a31","slug":"18"}},"MeasuredEvidence":{}},"Text":{"Collection":"func","Key":"xml-is-well-formed-document","SourceDatabase":"center","Version":"18","Locale":"en","Title":"xml_is_well_formed_document","Summary":"These functions check whether a text string represents well-formed XML, returning a Boolean result. xml_is_well_formed_document checks for a well-formed document, while xml_is_well_formed_content checks for well-formed content. xml_is_well_formed does the former if the xmloption configuration parameter is set to DOCUMENT, or the latter if it is set to CONTENT. This means that xml_is_well_formed is useful for seeing whether a simple cast to type xml will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of XMLPARSE will succeed.","BodyHTML":"These functions check whether a \u003ccode\u003etext\u003c/code\u003e string represents well-formed XML, returning a Boolean result. \u003ccode\u003exml_is_well_formed_document\u003c/code\u003e checks for a well-formed document, while \u003ccode\u003exml_is_well_formed_content\u003c/code\u003e checks for well-formed content. \u003ccode\u003exml_is_well_formed\u003c/code\u003e does the former if the \u003ca href=\"/docs/18/runtime-config-client.html#GUC-XMLOPTION\" rel=\"nofollow\"\u003exmloption\u003c/a\u003e configuration parameter is set to \u003ccode\u003eDOCUMENT\u003c/code\u003e, or the latter if it is set to \u003ccode\u003eCONTENT\u003c/code\u003e. This means that \u003ccode\u003exml_is_well_formed\u003c/code\u003e is useful for seeing whether a simple cast to type \u003ccode\u003exml\u003c/code\u003e will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of \u003ccode\u003eXMLPARSE\u003c/code\u003e will succeed.","SourceRevision":"wiki-repair-20261023:cc5db093f4bcbc2d9600246057a53762a9a08ce864daa04a2bca2af5034692b5","ContentHash":"dfcd79d8ad8d16b02e9d60c8178c561645f9952e0bdbc82b791f6073ff90dd8d","Payload":{"description":"These functions check whether a text string represents well-formed XML, returning a Boolean result. xml_is_well_formed_document checks for a well-formed document, while xml_is_well_formed_content checks for well-formed content. xml_is_well_formed does the former if the xmloption configuration parameter is set to DOCUMENT, or the latter if it is set to CONTENT. This means that xml_is_well_formed is useful for seeing whether a simple cast to type xml will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of XMLPARSE will succeed.","description_html":"These functions check whether a \u003ccode class=\"type\"\u003etext\u003c/code\u003e string represents well-formed XML, returning a Boolean result. \u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e checks for a well-formed document, while \u003ccode class=\"function\"\u003exml_is_well_formed_content\u003c/code\u003e checks for well-formed content. \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e does the former if the \u003ca href=\"/docs/18/runtime-config-client.html#GUC-XMLOPTION\"\u003exmloption\u003c/a\u003e configuration parameter is set to \u003ccode class=\"literal\"\u003eDOCUMENT\u003c/code\u003e, or the latter if it is set to \u003ccode class=\"literal\"\u003eCONTENT\u003c/code\u003e. This means that \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e is useful for seeing whether a simple cast to type \u003ccode class=\"type\"\u003exml\u003c/code\u003e will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of \u003ccode class=\"function\"\u003eXMLPARSE\u003c/code\u003e will succeed.","signatures":[{"description":"These functions check whether a text string represents well-formed XML, returning a Boolean result. xml_is_well_formed_document checks for a well-formed document, while xml_is_well_formed_content checks for well-formed content. xml_is_well_formed does the former if the xmloption configuration parameter is set to DOCUMENT, or the latter if it is set to CONTENT. This means that xml_is_well_formed is useful for seeing whether a simple cast to type xml will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of XMLPARSE will succeed.","description_html":"These functions check whether a \u003ccode class=\"type\"\u003etext\u003c/code\u003e string represents well-formed XML, returning a Boolean result. \u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e checks for a well-formed document, while \u003ccode class=\"function\"\u003exml_is_well_formed_content\u003c/code\u003e checks for well-formed content. \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e does the former if the \u003ca href=\"/docs/18/runtime-config-client.html#GUC-XMLOPTION\"\u003exmloption\u003c/a\u003e configuration parameter is set to \u003ccode class=\"literal\"\u003eDOCUMENT\u003c/code\u003e, or the latter if it is set to \u003ccode class=\"literal\"\u003eCONTENT\u003c/code\u003e. This means that \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e is useful for seeing whether a simple cast to type \u003ccode class=\"type\"\u003exml\u003c/code\u003e will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of \u003ccode class=\"function\"\u003eXMLPARSE\u003c/code\u003e will succeed.","description_zh":"这些函数检查一个 text 串是不是一个良构的 XML，返回一个布尔结果。xml_is_well_formed_document 检查一个良构的文档，而 xml_is_well_formed_content 检查良构的内容。如果 xmloption 配置参数被设置为 DOCUMENT，xml_is_well_formed 会做第一个函数的工作；如果配置参数被设置为 CONTENT，xml_is_well_formed 会做第二个函数的工作。这意味着 xml_is_well_formed 对于检查一个到类型 xml 的简单类型转换是否会成功非常有用，而其他两个函数对于检查 XMLPARSE 的对应变体是否会成功有用。","description_zh_html":"这些函数检查一个 \u003ccode class=\"type\"\u003etext\u003c/code\u003e 串是不是一个良构的 XML，返回一个布尔结果。\u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e 检查一个良构的文档，而 \u003ccode class=\"function\"\u003exml_is_well_formed_content\u003c/code\u003e 检查良构的内容。如果 \u003ca href=\"/docs/18/runtime-config-client.html#GUC-XMLOPTION\"\u003exmloption\u003c/a\u003e 配置参数被设置为 \u003ccode class=\"literal\"\u003eDOCUMENT\u003c/code\u003e，\u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 会做第一个函数的工作；如果配置参数被设置为 \u003ccode class=\"literal\"\u003eCONTENT\u003c/code\u003e，\u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 会做第二个函数的工作。这意味着 \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 对于检查一个到类型 \u003ccode class=\"type\"\u003exml\u003c/code\u003e 的简单类型转换是否会成功非常有用，而其他两个函数对于检查 \u003ccode class=\"function\"\u003eXMLPARSE\u003c/code\u003e 的对应变体是否会成功有用。","examples":[],"html":"\u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e ( \u003ccode class=\"type\"\u003etext\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003eboolean\u003c/code\u003e","returns":"boolean","text":"xml_is_well_formed_document ( text ) → boolean","zh_from":"same-version-manual"}]}},"RequestedLocale":"en","Fallback":false,"Versions":["10","11","12","13","14","15","16","17","18","19","20","9.1","9.2","9.3","9.4","9.5","9.6"],"Locales":["en","zh-Hans"],"Signatures":[{"Version":"18","Ordinal":0,"Hash":"4cecc23386dbf5cad3f70411e59d020b71362fa07d674abbaac8a860bb6b0341","Text":"xml_is_well_formed_document ( text ) → boolean","Returns":"boolean","Payload":{"description":"These functions check whether a text string represents well-formed XML, returning a Boolean result. xml_is_well_formed_document checks for a well-formed document, while xml_is_well_formed_content checks for well-formed content. xml_is_well_formed does the former if the xmloption configuration parameter is set to DOCUMENT, or the latter if it is set to CONTENT. This means that xml_is_well_formed is useful for seeing whether a simple cast to type xml will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of XMLPARSE will succeed.","description_html":"These functions check whether a \u003ccode class=\"type\"\u003etext\u003c/code\u003e string represents well-formed XML, returning a Boolean result. \u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e checks for a well-formed document, while \u003ccode class=\"function\"\u003exml_is_well_formed_content\u003c/code\u003e checks for well-formed content. \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e does the former if the \u003ca href=\"/docs/18/runtime-config-client.html#GUC-XMLOPTION\"\u003exmloption\u003c/a\u003e configuration parameter is set to \u003ccode class=\"literal\"\u003eDOCUMENT\u003c/code\u003e, or the latter if it is set to \u003ccode class=\"literal\"\u003eCONTENT\u003c/code\u003e. This means that \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e is useful for seeing whether a simple cast to type \u003ccode class=\"type\"\u003exml\u003c/code\u003e will succeed, whereas the other two functions are useful for seeing whether the corresponding variants of \u003ccode class=\"function\"\u003eXMLPARSE\u003c/code\u003e will succeed.","description_zh":"这些函数检查一个 text 串是不是一个良构的 XML，返回一个布尔结果。xml_is_well_formed_document 检查一个良构的文档，而 xml_is_well_formed_content 检查良构的内容。如果 xmloption 配置参数被设置为 DOCUMENT，xml_is_well_formed 会做第一个函数的工作；如果配置参数被设置为 CONTENT，xml_is_well_formed 会做第二个函数的工作。这意味着 xml_is_well_formed 对于检查一个到类型 xml 的简单类型转换是否会成功非常有用，而其他两个函数对于检查 XMLPARSE 的对应变体是否会成功有用。","description_zh_html":"这些函数检查一个 \u003ccode class=\"type\"\u003etext\u003c/code\u003e 串是不是一个良构的 XML，返回一个布尔结果。\u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e 检查一个良构的文档，而 \u003ccode class=\"function\"\u003exml_is_well_formed_content\u003c/code\u003e 检查良构的内容。如果 \u003ca href=\"/docs/18/runtime-config-client.html#GUC-XMLOPTION\"\u003exmloption\u003c/a\u003e 配置参数被设置为 \u003ccode class=\"literal\"\u003eDOCUMENT\u003c/code\u003e，\u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 会做第一个函数的工作；如果配置参数被设置为 \u003ccode class=\"literal\"\u003eCONTENT\u003c/code\u003e，\u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 会做第二个函数的工作。这意味着 \u003ccode class=\"function\"\u003exml_is_well_formed\u003c/code\u003e 对于检查一个到类型 \u003ccode class=\"type\"\u003exml\u003c/code\u003e 的简单类型转换是否会成功非常有用，而其他两个函数对于检查 \u003ccode class=\"function\"\u003eXMLPARSE\u003c/code\u003e 的对应变体是否会成功有用。","examples":[],"html":"\u003ccode class=\"function\"\u003exml_is_well_formed_document\u003c/code\u003e ( \u003ccode class=\"type\"\u003etext\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003eboolean\u003c/code\u003e","returns":"boolean","text":"xml_is_well_formed_document ( text ) → boolean","zh_from":"same-version-manual"}}],"Spellings":null,"SQLState":null,"Evidence":null}
