2 53.16. pg_prepared_statements #
4 The pg_prepared_statements view displays all the prepared statements
5 that are available in the current session. See PREPARE for more
6 information about prepared statements.
8 pg_prepared_statements contains one row for each prepared statement.
9 Rows are added to the view when a new prepared statement is created and
10 removed when a prepared statement is released (for example, via the
13 Table 53.16. pg_prepared_statements Columns
21 The identifier of the prepared statement
25 The query string submitted by the client to create this prepared
26 statement. For prepared statements created via SQL, this is the PREPARE
27 statement submitted by the client. For prepared statements created via
28 the frontend/backend protocol, this is the text of the prepared
31 prepare_time timestamptz
33 The time at which the prepared statement was created
35 parameter_types regtype[]
37 The expected parameter types for the prepared statement in the form of
38 an array of regtype. The OID corresponding to an element of this array
39 can be obtained by casting the regtype value to oid.
41 result_types regtype[]
43 The types of the columns returned by the prepared statement in the form
44 of an array of regtype. The OID corresponding to an element of this
45 array can be obtained by casting the regtype value to oid. If the
46 prepared statement does not provide a result (e.g., a DML statement),
47 then this field will be null.
51 true if the prepared statement was created via the PREPARE SQL command;
52 false if the statement was prepared via the frontend/backend protocol
56 Number of times generic plan was chosen
60 Number of times custom plan was chosen
62 The pg_prepared_statements view is read-only.