{"Entry":{"collection":"func","key":"to-regtypemod","name":"to_regtypemod","aliases":[],"metadata":{"changed_in":[],"changes":[{"descriptions_changed":false,"doc_overhaul":false,"from":"16","group_changed":null,"signatures":{"added":[],"removed":[]},"status":"added","to":"17"}],"content_hash":"e7711d93cd39f62a96d713ba313ac0aabb009fd665765f1b857968637d01e2f3","first_version":"17","group":"info","group_label":"System Information Functions And Operators","groups":["info"],"imported_at":"2026-09-27T17:57:29.374388+08:00","last_version":"20","name":"to_regtypemod","name_key":"to_regtypemod","position":28133,"present_in":["17","18","19","20"],"signature":"to_regtypemod ( text ) → integer","signature_count":1,"slug":"to-regtypemod","source_rev":"b7bd9cda","summary":"Parses a string of text, extracts a potential type name from it, and translates its type modifier, if any.","summary_zh":""}},"Definition":{"Collection":"func","Key":"to-regtypemod","SourceDatabase":"center","Version":"18","SourceTable":"func","SourceKey":"to-regtypemod","SourceRevision":"b7bd9cda","Facts":{"description":"Parses a string of text, extracts a potential type name from it, and translates its type modifier, if any. A syntax error in the string will result in an error; but if the string is a syntactically valid type name that happens not to be found in the catalogs, the result is NULL. The result is -1 if no type modifier is present.","description_html":"Parses a string of text, extracts a potential type name from it, and translates its type modifier, if any. A syntax error in the string will result in an error; but if the string is a syntactically valid type name that happens not to be found in the catalogs, the result is \u003ccode class=\"literal\"\u003eNULL\u003c/code\u003e. The result is \u003ccode class=\"literal\"\u003e-1\u003c/code\u003e if no type modifier is present.","description_zh":"","description_zh_html":"","doc":{"anchor":"FUNCTIONS-INFO-CATALOG-TABLE","file":"functions-info.html","slug":"18"},"group":"info","group_label":"System Information Functions And Operators","lang":"en","layout":"table-new","pages":["functions-info.html"],"prose_only":false,"signatures":[{"description":"Parses a string of text, extracts a potential type name from it, and translates its type modifier, if any. A syntax error in the string will result in an error; but if the string is a syntactically valid type name that happens not to be found in the catalogs, the result is NULL. The result is -1 if no type modifier is present.","description_html":"Parses a string of text, extracts a potential type name from it, and translates its type modifier, if any. A syntax error in the string will result in an error; but if the string is a syntactically valid type name that happens not to be found in the catalogs, the result is \u003ccode class=\"literal\"\u003eNULL\u003c/code\u003e. The result is \u003ccode class=\"literal\"\u003e-1\u003c/code\u003e if no type modifier is present.","description_zh":"","description_zh_html":"","examples":[{"expr":"format_type(to_regtype('varchar(32)'), to_regtypemod('varchar(32)'))","result":"character varying(32)"}],"html":"\u003ccode class=\"function\"\u003eto_regtypemod\u003c/code\u003e ( \u003ccode class=\"type\"\u003etext\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003einteger\u003c/code\u003e","returns":"integer","text":"to_regtypemod ( text ) → integer","zh_from":""}],"zh_from":""},"ManualEvidence":{"doc":{"anchor":"FUNCTIONS-INFO-CATALOG-TABLE","file":"functions-info.html","slug":"18"}},"MeasuredEvidence":{}},"Text":{"Collection":"func","Key":"to-regtypemod","SourceDatabase":"pgweb","Version":"18","Locale":"zh-Hans","Title":"to_regtypemod","Summary":"解析文本字符串，从中提取可能的类型名称，并转换其类型修饰符（如果有）。字符串中的语法错误会引发错误；但如果字符串是语法有效的类型名称，只是在系统目录中找不到，则结果为NULL。如果没有类型修饰符，则结果为-1。","BodyHTML":"解析文本字符串，从中提取可能的类型名称，并转换其类型修饰符（如果有）。字符串中的语法错误会引发错误；但如果字符串是语法有效的类型名称，只是在系统目录中找不到，则结果为\u003ccode\u003eNULL\u003c/code\u003e。如果没有类型修饰符，则结果为\u003ccode\u003e-1\u003c/code\u003e。\u003cpre\u003eto_regtypemod ( text ) → integer\u003c/pre\u003e解析文本字符串，从中提取可能的类型名称，并转换其类型修饰符（如果有）。字符串中的语法错误会引发错误；但如果字符串是语法有效的类型名称，只是在系统目录中找不到，则结果为\u003ccode\u003eNULL\u003c/code\u003e。如果没有类型修饰符，则结果为\u003ccode\u003e-1\u003c/code\u003e。","SourceRevision":"ca936764","ContentHash":"7d199950e142d76de01c4d3bd5b358d3ad6c27c45795ee8d2d0c7d2a8dd8f3f9","Payload":{"description_zh":"解析文本字符串，从中提取可能的类型名称，并转换其类型修饰符（如果有）。字符串中的语法错误会引发错误；但如果字符串是语法有效的类型名称，只是在系统目录中找不到，则结果为NULL。如果没有类型修饰符，则结果为-1。","description_zh_html":"解析文本字符串，从中提取可能的类型名称，并转换其类型修饰符（如果有）。字符串中的语法错误会引发错误；但如果字符串是语法有效的类型名称，只是在系统目录中找不到，则结果为\u003ccode class=\"literal\"\u003eNULL\u003c/code\u003e。如果没有类型修饰符，则结果为\u003ccode class=\"literal\"\u003e-1\u003c/code\u003e。","signatures":[{"description_zh":"解析文本字符串，从中提取可能的类型名称，并转换其类型修饰符（如果有）。字符串中的语法错误会引发错误；但如果字符串是语法有效的类型名称，只是在系统目录中找不到，则结果为NULL。如果没有类型修饰符，则结果为-1。","description_zh_html":"解析文本字符串，从中提取可能的类型名称，并转换其类型修饰符（如果有）。字符串中的语法错误会引发错误；但如果字符串是语法有效的类型名称，只是在系统目录中找不到，则结果为\u003ccode class=\"literal\"\u003eNULL\u003c/code\u003e。如果没有类型修饰符，则结果为\u003ccode class=\"literal\"\u003e-1\u003c/code\u003e。","returns":"integer","text":"to_regtypemod ( text ) → integer","zh_from":"doc"}],"zh_from":"doc"}},"RequestedLocale":"zh-Hans","Fallback":false,"Versions":["17","18","19","20"],"Locales":["en","zh-Hans"],"Signatures":[{"Version":"18","Ordinal":0,"Hash":"585d33558bd8c5b40002063c904913f92d863f24968e36b9ef627a2ed434ac7a","Text":"to_regtypemod ( text ) → integer","Returns":"integer","Payload":{"description":"Parses a string of text, extracts a potential type name from it, and translates its type modifier, if any. A syntax error in the string will result in an error; but if the string is a syntactically valid type name that happens not to be found in the catalogs, the result is NULL. The result is -1 if no type modifier is present.","description_html":"Parses a string of text, extracts a potential type name from it, and translates its type modifier, if any. A syntax error in the string will result in an error; but if the string is a syntactically valid type name that happens not to be found in the catalogs, the result is \u003ccode class=\"literal\"\u003eNULL\u003c/code\u003e. The result is \u003ccode class=\"literal\"\u003e-1\u003c/code\u003e if no type modifier is present.","description_zh":"","description_zh_html":"","examples":[{"expr":"format_type(to_regtype('varchar(32)'), to_regtypemod('varchar(32)'))","result":"character varying(32)"}],"html":"\u003ccode class=\"function\"\u003eto_regtypemod\u003c/code\u003e ( \u003ccode class=\"type\"\u003etext\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003einteger\u003c/code\u003e","returns":"integer","text":"to_regtypemod ( text ) → integer","zh_from":""}}],"Spellings":null,"SQLState":null,"Evidence":null}
