You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I have a reverse GSI on my table, but I fail to make it usable with ElectroDB. Basically, my normal keys are called (pk, sk), but I have a reverse index using (sk, pk). ElectroDB fails with an error message (see below).
Expected behavior
The Entity constructor should run without error.
Errors
This is the error that I get (see the Playground example):
The Sort Key (sk) on Access Pattern 'followings' references the field 'sk' which is already referenced by the Access Pattern(s) 'followers' as a Partition Key. Fields mapped to Partition Keys cannot be also mapped to Sort Keys.
Describe the bug
I have a reverse GSI on my table, but I fail to make it usable with ElectroDB. Basically, my normal keys are called (pk, sk), but I have a reverse index using (sk, pk). ElectroDB fails with an error message (see below).
ElectroDB Version
2.14.2
ElectroDB Playground Link
This one
Entity/Service Definitions
Include your entity model (or a model that sufficiently recreates your issue) to help troubleshoot.
Expected behavior
The Entity constructor should run without error.
Errors
This is the error that I get (see the Playground example):
Additional context
I can't believe the error message because having a reverse index is one of the usual tricks in DynamoDB applications. See https://aws.amazon.com/tutorials/design-a-database-for-a-mobile-app-with-dynamodb/module-4/ for an example.
What am I missing here?
The text was updated successfully, but these errors were encountered: