AWS aurora-dsql documentation change
Summary
Restructured documentation to categorize supported PostgreSQL data types into sections (Numeric, Character, Date/Time, etc.), added detailed tables with type-specific limits/storage/index support, and clarified query runtime data types including 'inet' for IP addresses.
Security assessment
The changes primarily reorganize and expand data type documentation without addressing security vulnerabilities or introducing security-specific features. While the 'inet' type (for IP addresses) is added, it is described as a general network data type for parsing logs and calculations, not as a security feature. No explicit security guidance, vulnerability fixes, or access control mechanisms are mentioned.
Diff
diff --git a/aurora-dsql/latest/userguide/working-with-postgresql-compatibility-supported-data-types.md b/aurora-dsql/latest/userguide/working-with-postgresql-compatibility-supported-data-types.md index bb548120f..3f6960cc5 100644 --- a//aurora-dsql/latest/userguide/working-with-postgresql-compatibility-supported-data-types.md +++ b//aurora-dsql/latest/userguide/working-with-postgresql-compatibility-supported-data-types.md @@ -5 +5 @@ -Date time precisionTypes supported during query runtime +Numeric data typesCharacter data typesDate and time data typesMiscellaneous data typesQuery runtime data types @@ -11 +11 @@ Amazon Aurora DSQL is provided as a Preview service. To learn more, see [Betas a -See the following table to learn about the supported core data types in Aurora DSQL +Aurora DSQL supports a subset of the common PostgreSQL types. @@ -13 +13,35 @@ See the following table to learn about the supported core data types in Aurora D -Name | Aliases | Description | Aurora DSQL Specific Limits | Storage Size | Can be part of a Primary/Secondary Index Key? +###### Topics + + * Numeric data types + + * Character data types + + * Date and time data types + + * Miscellaneous data types + + * Query runtime data types + + + + +## Numeric data types + +Aurora DSQL supports the following PostgreSQL numeric data types. + +Name | Aliases | Range and precision | Aurora DSQL limit | Storage size | Index support +---|---|---|---|---|--- +smallint | int2 | -32768 to +3276 | | 2 bytes | Yes +integer | int, int4 | -2147483648 to +2147483647 | | 4 bytes | Yes +bigint | int8 | -9223372036854775808 to +9223372036854775807 | | 8 bytes | Yes +real | float4 | 6 decimal digits precision | | 4 bytes | Yes +double precision | float8 | 15 decimal digits precision | | 8 bytes | Yes +numeric [ (p, s) ] | decimal [ (p, s) ] dec[ (p,s)] | Exact numeric of selectable precision. The maximum precision is 38 and the maximum scale is 37.2 | numeric (18,6) | 8 bytes + 2 bytes per precision digit. Maximum size is 27 bytes. | No + +2 – If you don't explicitly specify a size when you run `CREATE TABLE` or `ALTER TABLE ADD COLUMN`, then Aurora DSQL enforces the defaults. Aurora DSQL applies limits when you run `INSERT` or `UPDATE` statements. + +## Character data types + +Aurora DSQL supports the following PostgreSQL character data types. + +Name | Aliases | Description | Aurora DSQL limit | Storage size | Index support @@ -15,19 +49,4 @@ Name | Aliases | Description | Aurora DSQL Specific Limits | Storage Size | Can -smallint | int2 | signed two-byte integer. 32768 to +3276 | | 2 bytes | Yes -integer | int, int4 | signed four-byte integer. -2147483648 to +2147483647 | | 4 bytes | Yes -bigint | int8 | signed eight-byte integer. -9223372036854775808 to +9223372036854775807 | | 8 bytes | Yes -boolean | bool | logical Boolean (true/false) | | 1 byte | Yes -character [ (n) ] | char [ (n) ] | fixed-length character string | 4096 bytes 1 2 | variable up to 4100 bytes | Yes -character varying [ (n) ] | varchar [ (n) ] | variable-length character string | 65535 bytes 1 2 | variable up to 65539 bytes | Yes -bpchar [ (n) ] | | if fixed-length, alias for char if variable length, alias for varchar where trailing spaces are semantically insignificant | 4096 bytes 1 2 | variable up to 4100 bytes | Yes -text | | variable-length character string | 1 MiB 1 2 | variable up to 1MB limit | Yes -bytea | | binary data ("byte array") | 1 MiB 1 2 | variable up to 1MB limit | No -real | float4 | single precision floating-point number (4 bytes). 6 decimal digits precision | | 4 bytes | Yes -double precision | float8 | double precision floating-point number (8 bytes). 15 decimal digits precision | | 8 bytes | Yes -numeric [ (p, s) ] | decimal [ (p, s) ], dec[ (p,s)] | exact numeric of selectable precision. Up to 38 digits before the decimal point up to 37 digits after the decimal point | Max precision = 38 Max scale = 37 2 | 8 bytes + 2 bytes per precision digit. Max size 27 bytes | No -date | | calendar date (year, month, day) | | 4 bytes | Yes -time [ (p) ] [ without time zone ] | timestamp | time of day (no time zone) | | 8 bytes | Yes -time [ (p) ] with time zone | timetz | time of day, including time zone | | 12 bytes | No -timestamp [ (p) ] [ without time zone ] | | date and time (no time zone) | | 8 bytes | Yes -timestamp [ (p) ] with time zone | timestamptz | date and time, including time zone | | 8 bytes | Yes -interval [ fields ] [ (p) ] | | time span | | 16 bytes | No -UUID | | universally unique identifier (v4) | | 16 bytes | Yes +character [ (n) ] | char [ (n) ] | Fixed-length character string | 4096 bytes1 2 | Variable up to 4100 bytes | Yes +character varying [ (n) ] | varchar [ (n) ] | Variable-length character string | 65535 bytes1 2 | Variable up to 65539 bytes | Yes +bpchar [ (n) ] | | If fixed length, this is an alias for char. If variable length, this is an alias for varchar, where trailing spaces are semantically insignificant. | 4096 bytes1 2 | Variable up to 4100 bytes | Yes +text | | Variable-length character string | 1 MiB1 2 | Variable up to 1 MB | Yes @@ -37 +56,3 @@ UUID | | universally unique identifier (v4) | | 16 bytes | Yes -2 – If you don't explicitly specify a size when you run `CREATE TABLE` or `ALTER TABLE ADD COLUMN`, then Aurora DSQL enforces the defaults. Aurora DSQL applies limits when you run `INSERT` or `UPDATE`. +2 – If you don't explicitly specify a size when you run `CREATE TABLE` or `ALTER TABLE ADD COLUMN`, then Aurora DSQL enforces the defaults. Aurora DSQL applies limits when you run `INSERT` or `UPDATE` statements. + +## Date and time data types @@ -39 +60 @@ UUID | | universally unique identifier (v4) | | 16 bytes | Yes -The following are data types and their implicit limits. +Aurora DSQL supports the following PostgreSQL date and time data types. @@ -41,8 +62,8 @@ The following are data types and their implicit limits. -Name | Implicit Limit ----|--- -character [ (n) ] | 4096 bytes -bpchar [ (n) ] | 4096 bytes -character varying [ (n) ] | 65535 bytes -text | 1MB -bytea | 1 MB -numeric [ (p, s) ] | numeric (18,6) +Name | Aliases | Description | Range | Resolution | Storage size | Index support +---|---|---|---|---|---|--- +date | | Calendar date (year, month, day) | 4713 BC – 5874897 AD | 1 day | 4 bytes | Yes +time [ (p) ] [ without time zone ] | timestamp | Time of day, with no time zone | 0 – 1 | 1 microsecond | 8 bytes | Yes +time [ (p) ] with time zone | timetz | time of day, including time zone | 00:00:00+1559 – 24:00:00 –1559 | 1 microsecond | 12 bytes | No +timestamp [ (p) ] [ without time zone ] | | Date and time, with no time zone | 4713 BC – 294276 AD | 1 microsecond | 8 bytes | Yes +timestamp [ (p) ] with time zone | timestamptz | Date and time, including time zone | 4713 BC – 294276 AD | 1 microsecond | 8 bytes | Yes +interval [ fields ] [ (p) ] | | Time span | -178000000 years – 178000000 years | 1 microsecond | 16 bytes | No @@ -50 +71 @@ numeric [ (p, s) ] | numeric (18,6) -## Date time precision +## Miscellaneous data types @@ -52 +73 @@ numeric [ (p, s) ] | numeric (18,6) -The following are the supported date time data types in Aurora DSQL and their precision values. +Aurora DSQL supports the following miscellaneous PostgreSQL data types. @@ -54,8 +75,7 @@ The following are the supported date time data types in Aurora DSQL and their pr -Name | Low Value | High Value | Resolution ----|---|---|--- -timestamp [ (p) ] [ without time zone ] | 4713 BC | 294276 AD | 1 microsecond -timestamp [ (p) ] with time zone | 4713 BC | 294276 AD | 1 microsecond -date | 4713 BC | 5874897 AD | 1 day -time [ (p) ] [ without time zone ] | 0 | 1 | 1 microsecond -time [ (p) ] with time zone | 00:00:00+1559 | 24:00:00-1559 | 1 microsecond -interval [ fields ] [ (p) ] | -178000000 years | 178000000 years | 1 microsecond +Name | Aliases | Description | Aurora DSQL limit | Storage size | Index support +---|---|---|---|---|--- +boolean | bool | Logical Boolean (true/false) | | 1 byte | Yes +bytea | | Binary data ("byte array") | 1 MiB1 2 | Variable up to 1 MB limit | No +UUID | | Universally unique identifier (v4) | | 16 bytes | Yes + +1 – If you use this data type in a primary key or key column, the maximum size is limited to 255 bytes. @@ -63 +83 @@ interval [ fields ] [ (p) ] | -178000000 years | 178000000 years | 1 microsec -## Types supported during query runtime +2 – If you don't explicitly specify a size when you run `CREATE TABLE` or `ALTER TABLE ADD COLUMN`, then Aurora DSQL enforces the defaults. Aurora DSQL applies limits when you run `INSERT` or `UPDATE` statements. @@ -65 +85,10 @@ interval [ fields ] [ (p) ] | -178000000 years | 178000000 years | 1 microsec -Aurora DSQL supports all documented storage types when you apply type transformations, such as CAST and AS, when you run queries. The following types are supported only during query runtime. +## Query runtime data types + +Query runtime data types are internal data types used at query execution time. These types are distinct from the PostgreSQL-compatible types like `varchar` and `integer` that you define in your schema. Instead, these types are runtime representations that Aurora DSQL uses when processing a query. + +The following data types are supported only during query runtime: + +**Array type** + + +Aurora DSQL supports arrays of the supported data types. For example, you can have an array of integers. The function `string_to_array` splits a string into a PostgreSQL-style array using the comma delimiter (`,`. You can use arrays in expressions, function outputs, or temporary computations during query execution. @@ -67 +95,0 @@ Aurora DSQL supports all documented storage types when you apply type transforma - * Array types of all of the above types. @@ -75,2 +103 @@ Aurora DSQL supports all documented storage types when you apply type transforma - * inet – IPv4, IPv6 host addresses, and their subnets. For more information, see [inet in the PostgreSQL documentation](https://www.postgresql.org/docs/16/datatype-net-types.html#DATATYPE-INET). - +**inet type** @@ -78,0 +106 @@ Aurora DSQL supports all documented storage types when you apply type transforma +The data type represents IPv4, IPv6 host addresses, and their subnets. This type is useful when parsing logs, filtering on IP subnets, or doing network calculations within a query. For more information, see [inet in the PostgreSQL documentation](https://www.PostgreSQL.org/docs/16/datatype-net-types.html#DATATYPE-INET).