Nilotpal
Nilotpal

Reputation: 3588

How to remove the sort key of a table in dynamodb

I am stuck with removing sort key in dynamodb table. I need to know via AWS console UI or command line.

Thanks!

Upvotes: 4

Views: 4698

Answers (1)

fedonev
fedonev

Reputation: 25739

A DynamoDB table's Sort Key and Partition Key definitions cannot be changed.

(You can update an individual record's PK and SK values, but you cannot change the PK or SK setting.)

It is a typical pattern to use the generic key names PK and SK, for this reason (and that the pattern also enables a single-table design).

Upvotes: 7

Related Questions