

# Reference for the apg\$1plan\$1mgmt.dba\$1plans view for Aurora PostgreSQL-Compatible Edition
<a name="AuroraPostgreSQL.Optimize.dba_plans_view_Reference"></a>

The columns of plan information in the `apg_plan_mgmt.dba_plans` view include the following.


| dba\$1plans column | Description | 
| --- | --- | 
| cardinality\$1error |  A measure of the error between the estimated cardinality versus the actual cardinality. *Cardinality* is the number of table rows that the plan is to process. If the cardinality error is large, then it increases the likelihood that the plan isn't optimal. This column is populated by the [apg\$1plan\$1mgmt.evolve\$1plan\$1baselines](AuroraPostgreSQL.Optimize.Functions.md#AuroraPostgreSQL.Optimize.Functions.evolve_plan_baselines) function.   | 
| compatibility\$1level |  This parameter shows when a query plan was last validated. In Aurora PostgreSQL versions 12.19, 13.15, 14.12, 15.7, 16.3, and later, it displays the Aurora version number. For earlier versions, it displays a feature specific version number.  Keep this parameter value at its default setting. Aurora PostgreSQL automatically sets and updates this value.   | 
| created\$1by | The authenticated user (session\$1user) who created the plan. | 
| enabled |  An indicator of whether the plan is enabled or disabled. All plans are enabled by default. You can disable plans to prevent them from being used by the optimizer. To modify this value, use the [apg\$1plan\$1mgmt.set\$1plan\$1enabled](AuroraPostgreSQL.Optimize.Functions.md#AuroraPostgreSQL.Optimize.Functions.set_plan_enabled) function.   | 
| environment\$1variables |  The PostgreSQL Grand Unified Configuration (GUC) parameters and values that the optimizer has overridden at the time the plan was captured.   | 
| estimated\$1startup\$1cost | The estimated optimizer setup cost before the optimizer delivers rows of a table. | 
| estimated\$1total\$1cost | The estimated optimizer cost to deliver the final table row. | 
| execution\$1time\$1benefit\$1ms | The execution time benefit in milliseconds of enabling the plan. This column is populated by the [apg\$1plan\$1mgmt.evolve\$1plan\$1baselines](AuroraPostgreSQL.Optimize.Functions.md#AuroraPostgreSQL.Optimize.Functions.evolve_plan_baselines) function.  | 
| execution\$1time\$1ms | The estimated time in milliseconds that the plan would run. This column is populated by the [apg\$1plan\$1mgmt.evolve\$1plan\$1baselines](AuroraPostgreSQL.Optimize.Functions.md#AuroraPostgreSQL.Optimize.Functions.evolve_plan_baselines) function.  | 
| has\$1side\$1effects | A value that indicates that the SQL statement is a data manipulation language (DML) statement or a SELECT statement that contains a VOLATILE function.  | 
| last\$1used | This value is updated to the current date whenever the plan is either executed or when the plan is the query optimizer's minimum-cost plan. This value is stored in shared memory and periodically flushed to disk. To get the most up-to-date value, read the date from shared memory by calling the function apg\$1plan\$1mgmt.plan\$1last\$1used(sql\$1hash, plan\$1hash) instead of reading the last\$1used value. For additional information, see the [apg\$1plan\$1mgmt.plan\$1retention\$1period](AuroraPostgreSQL.Optimize.Parameters.md#AuroraPostgreSQL.Optimize.Parameters.plan_retention_period) parameter.  | 
| last\$1validated | The most recent date and time when it was verified that the plan could be recreated by either the [apg\$1plan\$1mgmt.validate\$1plans](AuroraPostgreSQL.Optimize.Functions.md#AuroraPostgreSQL.Optimize.Functions.validate_plans) function or the [apg\$1plan\$1mgmt.evolve\$1plan\$1baselines](AuroraPostgreSQL.Optimize.Functions.md#AuroraPostgreSQL.Optimize.Functions.evolve_plan_baselines) function. | 
| last\$1verified | The most recent date and time when a plan was verified to be the best-performing plan for the specified parameters by the [apg\$1plan\$1mgmt.evolve\$1plan\$1baselines](AuroraPostgreSQL.Optimize.Functions.md#AuroraPostgreSQL.Optimize.Functions.evolve_plan_baselines) function.  | 
| origin |  How the plan was captured with the [apg\$1plan\$1mgmt.capture\$1plan\$1baselines](AuroraPostgreSQL.Optimize.Parameters.md#AuroraPostgreSQL.Optimize.Parameters.capture_plan_baselines) parameter. Valid values include the following:  `M` – The plan was captured with manual plan capture. `A` – The plan was captured with automatic plan capture.  | 
| param\$1list |  The parameter values that were passed to the statement if this is a prepared statement.  | 
| plan\$1created | The date and time the plan that was created. | 
| plan\$1hash | The plan identifier. The combination of plan\$1hash and sql\$1hash uniquely identifies a specific plan. | 
| plan\$1outline | A representation of the plan that is used to recreate the actual execution plan, and that is database-independent. Operators in the tree correspond to operators that appear in the EXPLAIN output. | 
| planning\$1time\$1ms |  The actual time to run the planner, in milliseconds. This column is populated by the [apg\$1plan\$1mgmt.evolve\$1plan\$1baselines](AuroraPostgreSQL.Optimize.Functions.md#AuroraPostgreSQL.Optimize.Functions.evolve_plan_baselines) function.   | 
| queryId | A statement hash, as calculated by the pg\$1stat\$1statements extension. This isn't a stable or database-independent identifier because it depends on object identifiers (OIDs). The value will be 0 if compute\$1query\$1id is off when capturing the query plan. | 
| sql\$1hash | A hash value of the SQL statement text, normalized with literals removed. | 
| sql\$1text | The full text of the SQL statement. | 
| status |  A plan's status, which determines how the optimizer uses a plan. Valid values include the following.  [\[See the AWS documentation website for more details\]](http://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/AuroraPostgreSQL.Optimize.dba_plans_view_Reference.html)  | 
| stmt\$1name | The name of the SQL statement within a PREPARE statement. This value is an empty string for an unnamed prepared statement. This value is NULL for a nonprepared statement. | 
| total\$1time\$1benefit\$1ms |  The total time benefit in milliseconds of enabling this plan. This value considers both planning time and execution time. If this value is negative, there is a disadvantage to enabling this plan. This column is populated by the [apg\$1plan\$1mgmt.evolve\$1plan\$1baselines](AuroraPostgreSQL.Optimize.Functions.md#AuroraPostgreSQL.Optimize.Functions.evolve_plan_baselines) function.   | 