

# Cluster quotas and database limits in Amazon Aurora DSQL
<a name="CHAP_quotas"></a>

The following sections describe the cluster quotas and database limits for Aurora DSQL.

## Cluster quotas
<a name="SECTION_cluster-quotas"></a>

Your AWS account has the following cluster quotas in Aurora DSQL. To request an increase to the service quotas for single-Region and multi-Region clusters within a specific AWS Region, use the [Service Quotas](https://console.aws.amazon.com/servicequotas) console page. For other quota increases, contact AWS Support.


| Description | Default limit | Configurable? | Aurora DSQL error code | Error message | 
| --- | --- | --- | --- | --- | 
| Maximum single-Region clusters per AWS account | 20 clusters | Yes | API error code `ServiceQuotaExceededException : 402` | `You have reached the cluster limit.` | 
| Maximum multi-Region clusters per AWS account | 5 clusters | Yes | API error code `ServiceQuotaExceededException : 402` | `You have reached the cluster limit.` | 
| Maximum storage per cluster | 10 TiB default limit, up to 256 TiB with approved limit increase | Yes | `DISK_FULL(53100)` | `Current cluster size exceeds cluster size limit.` | 
| Maximum connections per cluster | 10,000 connections | Yes | `TOO_MANY_CONNECTIONS(53300)` | `Unable to accept connection, too many open connections.` | 
| Maximum connection rate per cluster | 100 connections per second | No | `CONFIGURED_LIMIT_EXCEEDED(53400)` | `Unable to accept connection, rate exceeded.` | 
| Maximum connection burst capacity per cluster | 1,000 connections | No | No error code | No error message | 
| Maximum concurrent restore jobs | 4 | No | No error code | No error message | 
| Connection Refill Rate  | 100 connections per second | No | No error code | No error message | 
| Maximum CDC streams per cluster | 5 streams | No | API error code `ServiceQuotaExceededException : 402` | `You have reached the stream limit.` | 

## Database limits in Aurora DSQL
<a name="SECTION_database-limits"></a>

The following table describes the database limits in Aurora DSQL.


| Description | Default limit | Configurable? | Aurora DSQL error code | Error message | 
| --- | --- | --- | --- | --- | 
| Maximum combined size of the columns used in a primary key | 1 KiB | No | `54000` | `ERROR: key size too large` | 
| Maximum combined size of the columns in a secondary index | 1 KiB | No | `54000` | `ERROR: key size too large` | 
| Maximum size of a row in a table | 2 MiB | No | `54000` | `ERROR: maximum row size exceeded` | 
| Maximum size of a column that's not part of an index | 1 MiB | No | `54000` | `ERROR: maximum column size exceeded` | 
| Maximum number of columns in a primary key or a secondary index | 8 | No | `54011` | `ERROR: more than 8 column keys in an index are not supported` | 
| Maximum number of columns in a table | 255 | No | `54011` | `ERROR: tables can have at most 255 columns` | 
| Maximum number of indexes in a table | 24 | No | `54000` | `ERROR: more than 24 indexes per table are not allowed` | 
| Maximum size of all data modified in a write transaction | 10 MiB | No | `54000` | `ERROR: transaction size limit 10mb exceeded DETAIL: Current transaction size {sizemb} 10mb` | 
| Maximum number of table rows that can be mutated in a transaction block | 3,000 rows per transaction. See [Aurora DSQL considerations for PostgreSQL compatibility](working-with-postgresql-compatibility-migration-guide.md#working-with-postgresql-compatibility-unsupported-limitations). | No | `54000` | `ERROR: transaction row limit exceeded` | 
| Maximum base amount of memory that a query operation can use | 128 MiB per transaction | No | `53200` | `ERROR: query requires too much temp space, out of memory.` | 
| Maximum number of schemas defined in a database | 10 | No | `54000` | `ERROR: more than 10 schemas not allowed` | 
| Maximum number of tables in a database | 1,000 tables | No | `54000` | `ERROR: creating more than 1000 tables not allowed` | 
| Maximum number of databases in a cluster | 1 | No | No error code | `ERROR: unsupported statement` | 
| Maximum transaction time | 5 minutes | No | `54000` | `ERROR: transaction age limit of 300s exceeded` | 
| Maximum connection duration | 60 minutes | No | No error code | No error message | 
| Maximum number of views in a database | 5,000 | No | `54000` | `ERROR: creating more than 5000 views not allowed` | 
| Maximum view definition size | 2 MiB | No | `54000` | `ERROR: view definition too large` | 
| Maximum number of sequences | 5,000 | No | `54000` | `ERROR: creating more than 5000 sequences is not allowed` | 

For data type limits specific to Aurora DSQL, see [Supported data types in Aurora DSQL](working-with-postgresql-compatibility-supported-data-types.md).