MeridianMERIDIAN

AWS ARN

Amazon Resource Name. Globally unique identifier for AWS resources in the format arn:partition:service:region:account-id:resource.

AWS ARN

technology.cloud.aws_arn

Amazon Resource Name. Globally unique identifier for AWS resources in the format arn:partition:service:region:account-id:resource.

Domain
technology
Category
cloud
Casts to
VARCHAR
Scope
Universal

Try it

CLI
$ finetype infer -i "arn:aws:s3:::my-bucket"
→ technology.cloud.aws_arn

DuckDB

Detect
SELECT finetype('arn:aws:s3:::my-bucket');
-- → 'technology.cloud.aws_arn'
Cast expression
CAST({col} AS VARCHAR)
Safe cast pipeline
-- Normalise and cast in one step
SELECT TRY_CAST(finetype_cast(my_column) AS VARCHAR) AS clean_value
FROM my_table
WHERE finetype(my_column) = 'technology.cloud.aws_arn';

Struct Expansion

Expression
account_id: REGEXP_EXTRACT({col}, '^arn:[^:]+:[^:]+:[^:]*:([^:]*):' )
partition: REGEXP_EXTRACT({col}, '^arn:([^:]+):')
region: REGEXP_EXTRACT({col}, '^arn:[^:]+:[^:]+:([^:]*):' )
resource: REGEXP_EXTRACT({col}, '^arn:[^:]+:[^:]+:[^:]*:[^:]*:(.+)$')
service: REGEXP_EXTRACT({col}, '^arn:[^:]+:([^:]+):')

JSON Schema

finetype schema technology.cloud.aws_arn
{
  "$id": "https://meridian.online/schemas/technology.cloud.aws_arn",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "description": "Amazon Resource Name. Globally unique identifier for AWS resources in the format arn:partition:service:region:account-id:resource.",
  "examples": [
    "arn:aws:s3:::my-bucket",
    "arn:aws:iam:: 123456789012:user/johndoe",
    "arn:aws:ec2:us-east-1: 123456789012:instance/i-1234567890abcdef0",
    "arn:aws:lambda:eu-west-1: 123456789012:function:my-function"
  ],
  "pattern": "^arn:(aws|aws-cn|aws-us-gov):[a-zA-Z0-9\\-]+:[a-z0-9\\-]*:\\d{0,12}:.+$",
  "title": "AWS ARN",
  "type": "string",
  "x-finetype-broad-type": "VARCHAR",
  "x-finetype-transform": "CAST({col} AS VARCHAR)"
}

Examples

arn:aws:s3:::my-bucketarn:aws:iam::123456789012:user/johndoearn:aws:ec2:us-east-1:123456789012:instance/i-1234567890abcdef0arn:aws:lambda:eu-west-1:123456789012:function:my-function

Aliases

amazon_resource_name

Type Registry