pg.ddx.io pgsql-general@postgresql.org mailing list archivehelp / color / mirror / Atom feed
Request for Official Technical Clarification on PostgreSQL statement_timeout Error 3+ messages / 3 participants [nested] [flat]
* Request for Official Technical Clarification on PostgreSQL statement_timeout Error @ 2026-10-25 13:17 이정호 <curly2620@nate.com> 0 siblings, 2 replies; 3+ messages in thread From: 이정호 @ 2026-10-25 13:17 UTC (permalink / raw) To: pgsql-general@lists.postgresql.org <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">Hello,</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">I am an automation system engineer in South Korea.</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">Our application executes SQL INSERT statements on a PostgreSQL database using VBScript.</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">During execution, we encountered the following error:</span></p> <p style="font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 13px; line-height: normal; font-family: Courier; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">canceling statement due to statement timeout</span></p> <p style="font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 13px; line-height: normal; font-family: Courier; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">Error while executing the query</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">We would like to obtain a technical clarification regarding the exact meaning of this error.</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">According to the PostgreSQL documentation, statement_timeout is measured from the time a command arrives at the server until it is completed.</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">Could you please confirm the following?</span></p> <ol style="list-style-type: decimal"> <li style="font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">Does this error indicate that PostgreSQL received the SQL command and canceled it because the configured statement_timeout limit was exceeded?</span></li> <li style="font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">Are SQL syntax errors, data type errors, and constraint violations reported separately from statement_timeout errors?</span></li> <li style="font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">Does this error confirm that the SQL statement was not completed within the configured time limit after reaching the PostgreSQL server?</span></li> </ol> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">We understand that identifying the underlying cause of the delay may require additional investigation.</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">However, our current request is specifically to confirm the technical meaning of this error message, rather than to determine responsibility for the delay.</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">We would greatly appreciate a written response based on PostgreSQL’s documented behavior.</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">Thank you for your assistance.</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">Best regards,</span></p> <p style="margin-bottom: 12px; font-style: normal; font-variant-caps: normal; font-width: normal; font-size: 20px; line-height: normal; font-family: "Times New Roman"; font-size-adjust: none; font-kerning: auto; font-variant-alternates: normal; font-variant-ligatures: normal; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-position: normal; font-variant-emoji: normal; font-feature-settings: normal; font-optical-sizing: auto; font-variation-settings: normal; -webkit-text-stroke-width: 0px; -webkit-text-stroke-color: rgb(0, 0, 0);"><span style="font-kerning: none;">Techwin Electric</span><span style="font-size: 12px; font-kerning: none;"><br> </span><span style="font-kerning: none;">Automation Engineering Team</span></p><div><span style="font-kerning: none;"><br></span></div> <img src="https://mail3.nate.com/app/msg/confirm/?usn=20027333&email=curly2620@nate.com&key=d4691d5971...; height="1" width="1" alt="" /> ^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Request for Official Technical Clarification on PostgreSQL statement_timeout Error @ 2026-11-09 14:41 David G. Johnston <david.g.johnston@gmail.com> parent: 이정호 <curly2620@nate.com> 1 sibling, 0 replies; 3+ messages in thread From: David G. Johnston @ 2026-11-09 14:41 UTC (permalink / raw) To: 이정호 <curly2620@nate.com>; +Cc: pgsql-general@lists.postgresql.org On Mon, Nov 9, 2026 at 5:47 AM 이정호 <curly2620@nate.com> wrote: > Hello, > > I am an automation system engineer in South Korea. > > Our application executes SQL INSERT statements on a PostgreSQL database > using VBScript. > > During execution, we encountered the following error: > > canceling statement due to statement timeout > > Error while executing the query > > We would like to obtain a technical clarification regarding the exact > meaning of this error. > > According to the PostgreSQL documentation, statement_timeout is measured > from the time a command arrives at the server until it is completed. > > Could you please confirm the following? > > 1. Does this error indicate that PostgreSQL received the SQL command > and canceled it because the configured statement_timeout limit was exceeded? > > Trivial to find out what error message that error triggers: postgres=# set statement_timeout = '1s'; SET postgres=# select pg_sleep(3000); ERROR: canceling statement due to statement timeout postgres=# You second message is likely from your client/application, not PostgreSQL > 1. Are SQL syntax errors, data type errors, and constraint violations > reported separately from statement_timeout errors? > > Yes. The first one encountered is reported. As is typical with nearly all software. > > 1. Does this error confirm that the SQL statement was not completed > within the configured time limit after reaching the PostgreSQL server? > > "The timeout is measured from the time a command arrives at the server" = "after reaching the PostgreSQL server" https://www.postgresql.org/docs/current/runtime-config-client.html#GUC-STATEMENT-TIMEOUT David J. ^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Request for Official Technical Clarification on PostgreSQL statement_timeout Error @ 2026-11-09 14:42 Laurenz Albe <laurenz.albe@cybertec.at> parent: 이정호 <curly2620@nate.com> 1 sibling, 0 replies; 3+ messages in thread From: Laurenz Albe @ 2026-11-09 14:42 UTC (permalink / raw) To: 이정호 <curly2620@nate.com>; pgsql-general@lists.postgresql.org On Sun, 2026-10-25 at 22:17 +0900, 이정호 wrote: > During execution, we encountered the following error: > > canceling statement due to statement timeout > Error while executing the query > > We would like to obtain a technical clarification regarding the exact meaning of this error. > According to the PostgreSQL documentation, statement_timeout is measured from the time a > command arrives at the server until it is completed. > Could you please confirm the following? > 1. Does this error indicate that PostgreSQL received the SQL command and canceled it > because the configured statement_timeout limit was exceeded? Yes. Is the error message not clear? > 2. Are SQL syntax errors, data type errors, and constraint violations reported > separately from statement_timeout errors? Yes. The statement is parsed *before* it can be executed. Syntax errors happen during parsing. For the statement to time out, it must be running. The statement cannot start running if there is a syntax error. > 3. Does this error confirm that the SQL statement was not completed within the > configured time limit after reaching the PostgreSQL server? Yes. You will notice that the message was an error message. An error is a condition that terminates the execution of a statement, so the statement wasn't completed. > We understand that identifying the underlying cause of the delay may require additional investigation. > However, our current request is specifically to confirm the technical meaning of this error message, > rather than to determine responsibility for the delay. > We would greatly appreciate a written response based on PostgreSQL’s documented behavior. The documentation describes that well, see https://www.postgresql.org/docs/current/runtime-config-client.html#GUC-STATEMENT-TIMEOUT Abort any statement that takes more than the specified amount of time. If log_min_error_statement is set to ERROR or lower, the statement that timed out will also be logged. If this value is specified without units, it is taken as milliseconds. A value of zero (the default) disables the timeout. The timeout is measured from the time a command arrives at the server until it is completed by the server. If multiple SQL statements appear in a single simple-query message, the timeout is applied to each statement separately. (PostgreSQL versions before 13 usually treated the timeout as applying to the whole query string.) In extended query protocol, the timeout starts running when any query-related message (Parse, Bind, Execute, Describe) arrives, and it is canceled by completion of an Execute or Sync message. Yours, Laurenz Albe ^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2026-11-09 14:42 UTC | newest] Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2026-10-25 13:17 Request for Official Technical Clarification on PostgreSQL statement_timeout Error 이정호 <curly2620@nate.com> 2026-11-09 14:41 ` David G. Johnston <david.g.johnston@gmail.com> 2026-11-09 14:42 ` Laurenz Albe <laurenz.albe@cybertec.at>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox