dynobase-icon
Dynobase

Error: One or more parameter values were invalid: some AttributeDefinitions are not used

Rafal Wilinski

Answered by Rafal Wilinski

Last updated: October 23rd, 2026

Solution

some AttributeDefinitions are not used means CreateTable includes attribute definitions that no table or secondary-index key uses. AttributeDefinitions describes key attributes, not every field an item may contain.

  1. Collect the attribute names used by the table KeySchema and every GSI and LSI KeySchema.
  2. Define each distinct key attribute once with its matching S, N or B type.
  3. Remove ordinary fields, including attributes listed only in an INCLUDE projection. You can write those fields to items without declaring them.
{
  "TableName": "Orders",
  "BillingMode": "PAY_PER_REQUEST",
  "AttributeDefinitions": [
    { "AttributeName": "pk", "AttributeType": "S" },
    { "AttributeName": "sk", "AttributeType": "S" }
  ],
  "KeySchema": [
    { "AttributeName": "pk", "KeyType": "HASH" },
    { "AttributeName": "sk", "KeyType": "RANGE" }
  ]
}

This table can still store status, total and document attributes. Add a definition for status only if a table or secondary-index key uses it. In Terraform, the equivalent rule applies to attribute blocks; in CloudFormation it applies to AttributeDefinitions.

See table creation and AWS documentation.

Dynobase is a Professional GUI Client for DynamoDB

Start your 7-day free trial today

Product Features

Download
/
Changelog
/
Pricing
/
Member Portal
/
Privacy
/
EULA
/
Twitter
© 2026 Dynobase
+
Still using AWS DynamoDB Console?
Try Dynobase to accelerate your DynamoDB workflow. Start your 7-day free trial today.