{"Entry":{"collection":"protocol","key":"startupmessage-f","name":"StartupMessage","aliases":["StartupMessage","Int32"],"metadata":{"aliases":["StartupMessage","Int32"],"category":"Frontend messages","content_hash":"976b03500e338e7a66c4df5b07e1eb504b4a5039336d9aee429d454885ef0c01","derived_content_hash":"79c38267225a4329f86e4672af5eb5071cbe72972ee241c3872834fcb154ca06","imported_at":"2026-09-30T00:40:44.588232+08:00","name":"StartupMessage","name_zh":"","slug":"startupmessage-f","summary":"StartupMessage is a frontend protocol message. Length of message contents in bytes, including self."}},"Definition":{"Collection":"protocol","Key":"startupmessage-f","SourceDatabase":"center","Version":"18","SourceTable":"protocol_message","SourceKey":"startupmessage-f","SourceRevision":"555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f","Facts":{"comparison_data":{"direction":"F","fields":[{"description":"Length of message contents in bytes, including self.","format":"Int32"},{"description":"The protocol version number. The most significant 16 bits are the major version number (3 for the protocol described here). The least significant 16 bits are the minor version number (2 for the protocol described here).","format":"Int32(196610)"},{"description":"The parameter name. Currently recognized names are: user The database user name to connect as. Required; there is no default. database The database to connect to. Defaults to the user name. options Command-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash ( \\ ); write \\\\ to represent a literal backslash. replication Used to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be true , false , or database , and the default is false . See Section 54.4 for details. In addition to the above, other parameters may be listed. Parameter names beginning with _pq_. are reserved for use as protocol extensions, while others are treated as run-time parameters to be set at backend start time. Such settings will be applied during backend start (after parsing the command-line arguments if any) and will act as session defaults.","format":"String"},{"description":"The database user name to connect as. Required; there is no default.","format":"user"},{"description":"The database to connect to. Defaults to the user name.","format":"database"},{"description":"Command-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash ( \\ ); write \\\\ to represent a literal backslash.","format":"options"},{"description":"Used to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be true , false , or database , and the default is false . See Section 54.4 for details.","format":"replication"},{"description":"The parameter value.","format":"String"}]},"comparison_hash":"b0e84a6731a2fc6c6bfa894a55c348aad046b4626f513682066294ceadc90424","description":["StartupMessage is a frontend protocol message. Length of message contents in bytes, including self."],"description_zh":"Int32 消息内容的长度（以字节为单位），包括其自身。 Int32(196610) 协议版本号。高 16 位为主版本号（此处描述的协议为 3）；低 16 位为次版本号（此处描述的协议为 2）。 协议版本号之后是一个或多个参数名与参数值字符串对。最后一个名称/值对之后必须有一个零字节作为终止符。参数可以按任意顺序出现。其中， user 是必需的，其余均为可选。每个参数按以下方式指定： String 参数名称。目前能够识别的名称如下： user 要连接的数据库用户名称。必填项；没有默认值。 database 要连接的数据库。默认为用户名。 options 后端的命令行参数。（已弃用，建议设置单独的运行时参数。）此字符串中的空格被视为分隔参数，除非用反斜杠（ \\ ）转义；写 \\\\ 表示字面反斜杠。 replication 用于以流复制模式连接，可以发出一小组复制命令而不是 SQL 语句。值可以是 true 、 false 或 database ，默认为 false 。详细信息请参见 第 54.4 节 。 除上述参数外，还可以列出其他参数。以 _pq_. 开头的参数名称保留用于协议扩展，其余参数则作为运行时参数，在后端启动时设置。这些设置会在后端启动期间应用（在解析命令行参数之后，如果有的话），并作为会话默认值。 String 参数值。","description_zh_html":"\u003cp\u003e协议消息 StartupMessage (F)。\u003c/p\u003e\u003ch3\u003e同版本中文手册定义\u003c/h3\u003e\u003cdd\u003e\u003cdiv class=\"variablelist\"\u003e\u003cdl class=\"variablelist\"\u003e\u003cdt\u003e\u003cspan class=\"term\"\u003eInt32\u003c/span\u003e \u003c/dt\u003e\u003cdd\u003e\u003cp\u003e\n         消息内容的长度（以字节为单位），包括其自身。\n        \u003c/p\u003e\u003c/dd\u003e\u003cdt\u003e\u003cspan class=\"term\"\u003eInt32(196610)\u003c/span\u003e \u003c/dt\u003e\u003cdd\u003e\u003cp\u003e\n         协议版本号。高 16 位为主版本号（此处描述的协议为 3）；低 16 位为次版本号（此处描述的协议为 2）。\n        \u003c/p\u003e\u003c/dd\u003e\u003c/dl\u003e\u003c/div\u003e\u003cp\u003e\n      协议版本号之后是一个或多个参数名与参数值字符串对。最后一个名称/值对之后必须有一个零字节作为终止符。参数可以按任意顺序出现。其中，\u003ccode class=\"literal\"\u003euser\u003c/code\u003e 是必需的，其余均为可选。每个参数按以下方式指定：\n     \u003c/p\u003e\u003cdiv class=\"variablelist\"\u003e\u003cdl class=\"variablelist\"\u003e\u003cdt\u003e\u003cspan class=\"term\"\u003eString\u003c/span\u003e \u003c/dt\u003e\u003cdd\u003e\u003cp\u003e\n         参数名称。目前能够识别的名称如下：\n\n         \u003c/p\u003e\u003cdiv class=\"variablelist\"\u003e\u003cdl class=\"variablelist\"\u003e\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003euser\u003c/code\u003e\u003c/span\u003e \u003c/dt\u003e\u003cdd\u003e\u003cp\u003e\n             要连接的数据库用户名称。必填项；没有默认值。\n            \u003c/p\u003e\u003c/dd\u003e\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003edatabase\u003c/code\u003e\u003c/span\u003e \u003c/dt\u003e\u003cdd\u003e\u003cp\u003e\n             要连接的数据库。默认为用户名。\n            \u003c/p\u003e\u003c/dd\u003e\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003eoptions\u003c/code\u003e\u003c/span\u003e \u003c/dt\u003e\u003cdd\u003e\u003cp\u003e\n             后端的命令行参数。（已弃用，建议设置单独的运行时参数。）此字符串中的空格被视为分隔参数，除非用反斜杠（\u003ccode class=\"literal\"\u003e\\\u003c/code\u003e）转义；写\u003ccode class=\"literal\"\u003e\\\\\u003c/code\u003e 表示字面反斜杠。\n            \u003c/p\u003e\u003c/dd\u003e\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003ereplication\u003c/code\u003e\u003c/span\u003e \u003c/dt\u003e\u003cdd\u003e\u003cp\u003e\n             用于以流复制模式连接，可以发出一小组复制命令而不是 SQL 语句。值可以是 \u003ccode class=\"literal\"\u003etrue\u003c/code\u003e、\u003ccode class=\"literal\"\u003efalse\u003c/code\u003e 或 \u003ccode class=\"literal\"\u003edatabase\u003c/code\u003e，默认为 \u003ccode class=\"literal\"\u003efalse\u003c/code\u003e。详细信息请参见\u003ca class=\"xref\" href=\"/zh/docs/18/protocol-replication.html\"\u003e第 54.4 节\u003c/a\u003e。\n            \u003c/p\u003e\u003c/dd\u003e\u003c/dl\u003e\u003c/div\u003e\u003cp\u003e\n\n         除上述参数外，还可以列出其他参数。以\u003ccode class=\"literal\"\u003e_pq_.\u003c/code\u003e开头的参数名称保留用于协议扩展，其余参数则作为运行时参数，在后端启动时设置。这些设置会在后端启动期间应用（在解析命令行参数之后，如果有的话），并作为会话默认值。\n        \u003c/p\u003e\u003c/dd\u003e\u003cdt\u003e\u003cspan class=\"term\"\u003eString\u003c/span\u003e \u003c/dt\u003e\u003cdd\u003e\u003cp\u003e\n         参数值。\n        \u003c/p\u003e\u003c/dd\u003e\u003c/dl\u003e\u003c/div\u003e\u003c/dd\u003e\u003cp\u003e\u003ca href=\"/zh/docs/18/protocol-message-formats.html#PROTOCOL-MESSAGE-FORMATS-STARTUPMESSAGE\"\u003e查看完整中文手册与上下文\u003c/a\u003e。\u003c/p\u003e","direction":"F","facts":[{"label":"Direction","value":"Frontend → backend"},{"label":"First wire field","value":"Int32"},{"label":"Field entries","value":"8"},{"label":"Documented flow contexts","value":"Canceling Requests in Progress; SSL Session Encryption; GSSAPI Session Encryption"}],"facts_zh":[{"label":"方向","value":"前端 → 后端"},{"label":"首个线上协议字段","value":"Int32"},{"label":"字段条目","value":"8"},{"label":"手册中的交互阶段","value":"取消正在执行的请求；SSL 会话加密；GSSAPI 会话加密"}],"fields":[{"description":"Length of message contents in bytes, including self.","format":"Int32"},{"description":"The protocol version number. The most significant 16 bits are the major version number (3 for the protocol described here). The least significant 16 bits are the minor version number (2 for the protocol described here).","format":"Int32(196610)"},{"description":"The parameter name. Currently recognized names are: user The database user name to connect as. Required; there is no default. database The database to connect to. Defaults to the user name. options Command-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash ( \\ ); write \\\\ to represent a literal backslash. replication Used to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be true , false , or database , and the default is false . See Section 54.4 for details. In addition to the above, other parameters may be listed. Parameter names beginning with _pq_. are reserved for use as protocol extensions, while others are treated as run-time parameters to be set at backend start time. Such settings will be applied during backend start (after parsing the command-line arguments if any) and will act as session defaults.","format":"String"},{"description":"The database user name to connect as. Required; there is no default.","format":"user"},{"description":"The database to connect to. Defaults to the user name.","format":"database"},{"description":"Command-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash ( \\ ); write \\\\ to represent a literal backslash.","format":"options"},{"description":"Used to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be true , false , or database , and the default is false . See Section 54.4 for details.","format":"replication"},{"description":"The parameter value.","format":"String"}],"manual_html":"\u003cdl\u003e\u003cdd\u003e\n\u003cdiv class=\"variablelist\"\u003e\n\u003cdl class=\"variablelist\"\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003eInt32\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eLength of message contents in bytes, including self.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003eInt32(196610)\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe protocol version number. The most significant 16 bits are the major version number (3 for the protocol described here). The least significant 16 bits are the minor version number (2 for the protocol described here).\u003c/p\u003e\n\u003c/dd\u003e\n\u003c/dl\u003e\n\u003c/div\u003e\n\u003cp\u003eThe protocol version number is followed by one or more pairs of parameter name and value strings. A zero byte is required as a terminator after the last name/value pair. Parameters can appear in any order. \u003ccode class=\"literal\"\u003euser\u003c/code\u003e is required, others are optional. Each parameter is specified as:\u003c/p\u003e\n\u003cdiv class=\"variablelist\"\u003e\n\u003cdl class=\"variablelist\"\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003eString\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe parameter name. Currently recognized names are:\u003c/p\u003e\n\u003cdiv class=\"variablelist\"\u003e\n\u003cdl class=\"variablelist\"\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003euser\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe database user name to connect as. Required; there is no default.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003edatabase\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe database to connect to. Defaults to the user name.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003eoptions\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eCommand-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash (\u003ccode class=\"literal\"\u003e\\\u003c/code\u003e); write \u003ccode class=\"literal\"\u003e\\\\\u003c/code\u003e to represent a literal backslash.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003ereplication\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eUsed to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be \u003ccode class=\"literal\"\u003etrue\u003c/code\u003e, \u003ccode class=\"literal\"\u003efalse\u003c/code\u003e, or \u003ccode class=\"literal\"\u003edatabase\u003c/code\u003e, and the default is \u003ccode class=\"literal\"\u003efalse\u003c/code\u003e. See \u003ca class=\"xref\" href=\"/docs/18/protocol-replication.html\" title=\"54.4. Streaming Replication Protocol\"\u003eSection 54.4\u003c/a\u003e for details.\u003c/p\u003e\n\u003c/dd\u003e\n\u003c/dl\u003e\n\u003c/div\u003e\n\u003cp\u003eIn addition to the above, other parameters may be listed. Parameter names beginning with \u003ccode class=\"literal\"\u003e_pq_.\u003c/code\u003e are reserved for use as protocol extensions, while others are treated as run-time parameters to be set at backend start time. Such settings will be applied during backend start (after parsing the command-line arguments if any) and will act as session defaults.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003eString\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe parameter value.\u003c/p\u003e\n\u003c/dd\u003e\n\u003c/dl\u003e\n\u003c/div\u003e\n\u003c/dd\u003e\u003c/dl\u003e","manual_path":"/docs/18/protocol-message-formats.html","related":[{"label":"Protocol flow and exchange examples","url":"/docs/18/protocol-flow.html"},{"label":"Protocol overview","url":"/docs/18/protocol-overview.html"},{"label":"Canceling Requests in Progress","url":"/docs/18/protocol-flow.html#PROTOCOL-FLOW-CANCELING-REQUESTS"},{"label":"SSL Session Encryption","url":"/docs/18/protocol-flow.html#PROTOCOL-FLOW-SSL"},{"label":"GSSAPI Session Encryption","url":"/docs/18/protocol-flow.html#PROTOCOL-FLOW-GSSAPI"}],"release":{"channel":"stable","label":"18.6","major":"18","ref":"https://ftp.postgresql.org/pub/source/v18.6/postgresql-18.6.tar.bz2","revision":"555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f"},"sections":[{"paragraphs":["The complete definition below retains repetition, counts and conditional fields. A numbered table row is a documented field definition, not a fixed byte offset. Integer encodings and flow rules follow the same-version protocol chapter."],"title":"Framing and repetition"}],"sections_zh":[{"paragraphs":["下方完整定义保留重复项、计数与条件字段。表格行号表示文档中的字段定义，并非固定字节偏移量。整数编码与交互流程以同版本协议章节为准。"],"title":"消息边界与重复字段"}],"signature":"StartupMessage (F)","sources":[{"label":"PostgreSQL 18 English manual","path":"protocol-message-formats.html","sha256":"53f37652ac2c089e30ada87d8aee7bdd0f26695b03f275302e526a807d2a1f23","url":"/docs/18/protocol-message-formats.html#PROTOCOL-MESSAGE-FORMATS-STARTUPMESSAGE"}],"tables":[{"columns":[{"key":"c0","label":"Position"},{"key":"c1","label":"Format"},{"key":"c2","label":"Meaning"}],"key":"fields","rows":[{"c0":"1","c1":"Int32","c2":"Length of message contents in bytes, including self."},{"c0":"2","c1":"Int32(196610)","c2":"The protocol version number. The most significant 16 bits are the major version number (3 for the protocol described here). The least significant 16 bits are the minor version number (2 for the protocol described here)."},{"c0":"3","c1":"String","c2":"The parameter name. Currently recognized names are: user The database user name to connect as. Required; there is no default. database The database to connect to. Defaults to the user name. options Command-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash ( \\ ); write \\\\ to represent a literal backslash. replication Used to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be true , false , or database , and the default is false . See Section 54.4 for details. In addition to the above, other parameters may be listed. Parameter names beginning with _pq_. are reserved for use as protocol extensions, while others are treated as run-time parameters to be set at backend start time. Such settings will be applied during backend start (after parsing the command-line arguments if any) and will act as session defaults."},{"c0":"4","c1":"user","c2":"The database user name to connect as. Required; there is no default."},{"c0":"5","c1":"database","c2":"The database to connect to. Defaults to the user name."},{"c0":"6","c1":"options","c2":"Command-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash ( \\ ); write \\\\ to represent a literal backslash."},{"c0":"7","c1":"replication","c2":"Used to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be true , false , or database , and the default is false . See Section 54.4 for details."},{"c0":"8","c1":"String","c2":"The parameter value."}],"title":"Wire fields in documented order"}],"tables_zh":[{"columns":[{"key":"c0","label":"位置"},{"key":"c1","label":"格式"},{"key":"c2","label":"含义"}],"key":"fields","rows":[{"c0":"1","c1":"Int32","c2":"消息内容的长度（以字节为单位），包括其自身。"},{"c0":"2","c1":"Int32(196610)","c2":"协议版本号。高 16 位为主版本号（此处描述的协议为 3）；低 16 位为次版本号（此处描述的协议为 2）。"},{"c0":"3","c1":"字符串","c2":"参数名称。目前识别以下名称：user 为连接所用的数据库用户名，必填且没有默认值；database 为要连接的数据库，默认为用户名；options 为传给后端的命令行参数，此用法已弃用，建议单独设置各运行时参数。options 字符串中的空格用于分隔参数，除非用反斜杠（\\）转义；两个反斜杠（\\\\）表示一个字面反斜杠。replication 用于以流复制模式连接，此时可执行少量复制命令而非 SQL 语句，其值可为 true、false 或 database，默认为 false，详情参见第 54.4 节。还可以列出其他参数：以 _pq_. 开头的名称保留给协议扩展，其他名称被视为后端启动时设置的运行时参数。这些设置在后端启动时（若有命令行参数，则在其解析之后）应用，并作为会话默认值。"},{"c0":"4","c1":"user","c2":"要连接的数据库用户名称。必填项；没有默认值。"},{"c0":"5","c1":"database","c2":"要连接的数据库。默认为用户名。"},{"c0":"6","c1":"options","c2":"后端的命令行参数。（已弃用，建议设置单独的运行时参数。）此字符串中的空格被视为分隔参数，除非用反斜杠（ \\ ）转义；写 \\\\ 表示字面反斜杠。"},{"c0":"7","c1":"replication","c2":"用于以流复制模式连接，可以发出一小组复制命令而不是SQL语句。值可以是 true 、 false 或 database ，默认为 false 。详细信息请参见 第 54.4 节 。"},{"c0":"8","c1":"字符串","c2":"参数值。"}],"title":"按手册顺序排列的线上协议字段"}],"zh_from":{"authored_translation":"source-derived-identity","body_sha256":"4c81501a6314f850748503c67238e04a8983207d3ce8221fe4bd1fc28a37cc49","kind":"same-version-chinese-manual-with-source-derived-identity","manual":{"anchor":"PROTOCOL-MESSAGE-FORMATS-STARTUPMESSAGE","build_id":107,"extraction":"exact-definition","fragment_sha256":"5a369aa72ca27db032a77028571513284f02626b829125db950b123a8ca70c0e","locale":"zh-Hans","page_key":"protocol-message-formats.html","source_hash":"0be0a37b38d80c96c157ca9fcfe9222995654664aad8136f7ac2b1b552f6753a","source_revision":"unknown:rendered-translation-baseline","translated_from_revision":null,"translation_revision":"git:b1b500221dbe5437cfca004d6b04d3f6e422765d;html-sha256:08e987a66af27b98444a8057c256314eafa13611a3fb9e888214fc436824244b","url":"/zh/docs/18/protocol-message-formats.html#PROTOCOL-MESSAGE-FORMATS-STARTUPMESSAGE","version":"18"},"runtime_rerun":false,"source_facts_revision":"555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f"}},"ManualEvidence":{"manual_path":"/docs/18/protocol-message-formats.html","release":{"channel":"stable","label":"18.6","major":"18","ref":"https://ftp.postgresql.org/pub/source/v18.6/postgresql-18.6.tar.bz2","revision":"555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f"},"sources":[{"label":"PostgreSQL 18 English manual","path":"protocol-message-formats.html","sha256":"53f37652ac2c089e30ada87d8aee7bdd0f26695b03f275302e526a807d2a1f23","url":"/docs/18/protocol-message-formats.html#PROTOCOL-MESSAGE-FORMATS-STARTUPMESSAGE"}]},"MeasuredEvidence":{}},"Text":{"Collection":"protocol","Key":"startupmessage-f","SourceDatabase":"center","Version":"18","Locale":"en","Title":"StartupMessage","Summary":"StartupMessage is a frontend protocol message. Length of message contents in bytes, including self.","BodyHTML":"\u003cdl\u003e\u003cdd\u003e\n\u003cdiv\u003e\n\u003cdl\u003e\n\u003cdt\u003e\u003cspan\u003eInt32\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eLength of message contents in bytes, including self.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan\u003eInt32(196610)\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe protocol version number. The most significant 16 bits are the major version number (3 for the protocol described here). The least significant 16 bits are the minor version number (2 for the protocol described here).\u003c/p\u003e\n\u003c/dd\u003e\n\u003c/dl\u003e\n\u003c/div\u003e\n\u003cp\u003eThe protocol version number is followed by one or more pairs of parameter name and value strings. A zero byte is required as a terminator after the last name/value pair. Parameters can appear in any order. \u003ccode\u003euser\u003c/code\u003e is required, others are optional. Each parameter is specified as:\u003c/p\u003e\n\u003cdiv\u003e\n\u003cdl\u003e\n\u003cdt\u003e\u003cspan\u003eString\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe parameter name. Currently recognized names are:\u003c/p\u003e\n\u003cdiv\u003e\n\u003cdl\u003e\n\u003cdt\u003e\u003cspan\u003e\u003ccode\u003euser\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe database user name to connect as. Required; there is no default.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan\u003e\u003ccode\u003edatabase\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe database to connect to. Defaults to the user name.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan\u003e\u003ccode\u003eoptions\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eCommand-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash (\u003ccode\u003e\\\u003c/code\u003e); write \u003ccode\u003e\\\\\u003c/code\u003e to represent a literal backslash.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan\u003e\u003ccode\u003ereplication\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eUsed to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be \u003ccode\u003etrue\u003c/code\u003e, \u003ccode\u003efalse\u003c/code\u003e, or \u003ccode\u003edatabase\u003c/code\u003e, and the default is \u003ccode\u003efalse\u003c/code\u003e. See \u003ca href=\"/docs/18/protocol-replication.html\" rel=\"nofollow\"\u003eSection 54.4\u003c/a\u003e for details.\u003c/p\u003e\n\u003c/dd\u003e\n\u003c/dl\u003e\n\u003c/div\u003e\n\u003cp\u003eIn addition to the above, other parameters may be listed. Parameter names beginning with \u003ccode\u003e_pq_.\u003c/code\u003e are reserved for use as protocol extensions, while others are treated as run-time parameters to be set at backend start time. Such settings will be applied during backend start (after parsing the command-line arguments if any) and will act as session defaults.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan\u003eString\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe parameter value.\u003c/p\u003e\n\u003c/dd\u003e\n\u003c/dl\u003e\n\u003c/div\u003e\n\u003c/dd\u003e\u003c/dl\u003e","SourceRevision":"555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f","ContentHash":"ae06d541e6d92fc5843dcab7591143b3f8f03bca7b72f451d2f48a28693ca161","Payload":{"description":["StartupMessage is a frontend protocol message. Length of message contents in bytes, including self."],"manual_html":"\u003cdl\u003e\u003cdd\u003e\n\u003cdiv class=\"variablelist\"\u003e\n\u003cdl class=\"variablelist\"\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003eInt32\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eLength of message contents in bytes, including self.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003eInt32(196610)\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe protocol version number. The most significant 16 bits are the major version number (3 for the protocol described here). The least significant 16 bits are the minor version number (2 for the protocol described here).\u003c/p\u003e\n\u003c/dd\u003e\n\u003c/dl\u003e\n\u003c/div\u003e\n\u003cp\u003eThe protocol version number is followed by one or more pairs of parameter name and value strings. A zero byte is required as a terminator after the last name/value pair. Parameters can appear in any order. \u003ccode class=\"literal\"\u003euser\u003c/code\u003e is required, others are optional. Each parameter is specified as:\u003c/p\u003e\n\u003cdiv class=\"variablelist\"\u003e\n\u003cdl class=\"variablelist\"\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003eString\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe parameter name. Currently recognized names are:\u003c/p\u003e\n\u003cdiv class=\"variablelist\"\u003e\n\u003cdl class=\"variablelist\"\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003euser\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe database user name to connect as. Required; there is no default.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003edatabase\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe database to connect to. Defaults to the user name.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003eoptions\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eCommand-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash (\u003ccode class=\"literal\"\u003e\\\u003c/code\u003e); write \u003ccode class=\"literal\"\u003e\\\\\u003c/code\u003e to represent a literal backslash.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003e\u003ccode class=\"literal\"\u003ereplication\u003c/code\u003e\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eUsed to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be \u003ccode class=\"literal\"\u003etrue\u003c/code\u003e, \u003ccode class=\"literal\"\u003efalse\u003c/code\u003e, or \u003ccode class=\"literal\"\u003edatabase\u003c/code\u003e, and the default is \u003ccode class=\"literal\"\u003efalse\u003c/code\u003e. See \u003ca class=\"xref\" href=\"/docs/18/protocol-replication.html\" title=\"54.4. Streaming Replication Protocol\"\u003eSection 54.4\u003c/a\u003e for details.\u003c/p\u003e\n\u003c/dd\u003e\n\u003c/dl\u003e\n\u003c/div\u003e\n\u003cp\u003eIn addition to the above, other parameters may be listed. Parameter names beginning with \u003ccode class=\"literal\"\u003e_pq_.\u003c/code\u003e are reserved for use as protocol extensions, while others are treated as run-time parameters to be set at backend start time. Such settings will be applied during backend start (after parsing the command-line arguments if any) and will act as session defaults.\u003c/p\u003e\n\u003c/dd\u003e\n\u003cdt\u003e\u003cspan class=\"term\"\u003eString\u003c/span\u003e\u003c/dt\u003e\n\u003cdd\u003e\n\u003cp\u003eThe parameter value.\u003c/p\u003e\n\u003c/dd\u003e\n\u003c/dl\u003e\n\u003c/div\u003e\n\u003c/dd\u003e\u003c/dl\u003e","related":[{"label":"Protocol flow and exchange examples","url":"/docs/18/protocol-flow.html"},{"label":"Protocol overview","url":"/docs/18/protocol-overview.html"},{"label":"Canceling Requests in Progress","url":"/docs/18/protocol-flow.html#PROTOCOL-FLOW-CANCELING-REQUESTS"},{"label":"SSL Session Encryption","url":"/docs/18/protocol-flow.html#PROTOCOL-FLOW-SSL"},{"label":"GSSAPI Session Encryption","url":"/docs/18/protocol-flow.html#PROTOCOL-FLOW-GSSAPI"}],"sections":[{"paragraphs":["The complete definition below retains repetition, counts and conditional fields. A numbered table row is a documented field definition, not a fixed byte offset. Integer encodings and flow rules follow the same-version protocol chapter."],"title":"Framing and repetition"}],"tables":[{"columns":[{"key":"c0","label":"Position"},{"key":"c1","label":"Format"},{"key":"c2","label":"Meaning"}],"key":"fields","rows":[{"c0":"1","c1":"Int32","c2":"Length of message contents in bytes, including self."},{"c0":"2","c1":"Int32(196610)","c2":"The protocol version number. The most significant 16 bits are the major version number (3 for the protocol described here). The least significant 16 bits are the minor version number (2 for the protocol described here)."},{"c0":"3","c1":"String","c2":"The parameter name. Currently recognized names are: user The database user name to connect as. Required; there is no default. database The database to connect to. Defaults to the user name. options Command-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash ( \\ ); write \\\\ to represent a literal backslash. replication Used to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be true , false , or database , and the default is false . See Section 54.4 for details. In addition to the above, other parameters may be listed. Parameter names beginning with _pq_. are reserved for use as protocol extensions, while others are treated as run-time parameters to be set at backend start time. Such settings will be applied during backend start (after parsing the command-line arguments if any) and will act as session defaults."},{"c0":"4","c1":"user","c2":"The database user name to connect as. Required; there is no default."},{"c0":"5","c1":"database","c2":"The database to connect to. Defaults to the user name."},{"c0":"6","c1":"options","c2":"Command-line arguments for the backend. (This is deprecated in favor of setting individual run-time parameters.) Spaces within this string are considered to separate arguments, unless escaped with a backslash ( \\ ); write \\\\ to represent a literal backslash."},{"c0":"7","c1":"replication","c2":"Used to connect in streaming replication mode, where a small set of replication commands can be issued instead of SQL statements. Value can be true , false , or database , and the default is false . See Section 54.4 for details."},{"c0":"8","c1":"String","c2":"The parameter value."}],"title":"Wire fields in documented order"}]}},"RequestedLocale":"en","Fallback":false,"Versions":["10","11","12","13","14","15","16","17","18","19","20"],"Locales":["en","zh-Hans"],"Signatures":null,"Spellings":null,"SQLState":null,"Evidence":null}
