-
Notifications
You must be signed in to change notification settings - Fork 81
Open
Description
Maybe there's an explanation for this, but I can't understand why or if it's a bug.
If I set my indexes like these:
{ indexes: {
byKey: {
pk: {
field: "pk",
composite: ["id"],
},
sk: {
field: "sk",
composite: ["createdAt"],
},
},
byUserId: {
index: "gsi1pk-gsi1sk-index",
pk: {
field: "gsi1pk",
composite: ["requestUserId"],
},
sk: {
field: "gsi1sk",
composite: ["createdAt"],
},
},
}
}For some reason gsi1pk doesn't save the value for the field, even though there is one:
Now, if I change the value of gs1sk to some other property, like "requestPath", now gsi1pk works:
I thought this might be related with "createdAt" being used in the primary index, but it also doesn't work if I use "updatedAt" in the gsi1sk:
Maybe this is something about dates, idk, but if I add a new property "timestamp" which I load with the same exact value as "createdAt", then it works again:
Can anyone please help understand what's going on? Seems to be bug, but I can't be sure, thanks.
Metadata
Metadata
Assignees
Labels
No labels