Describe the bug
In cases when Dynamo items are queried via GSI with limited projection fields and then "updated" via the update() method, the fields that are not part of the GSI projected get implicitly removed.
The "BaoPham\DynamoDb\DynamoDbQueryBuilder" save() method uses the AWS putItem() instead of the updateItem() when the record exists.
Schema
GSI with a limited number of fields
Version info
- Laravel: 9
- laravel-dynamodb: 6.4.0
Describe the bug
In cases when Dynamo items are queried via GSI with limited projection fields and then "updated" via the
update()method, the fields that are not part of the GSI projected get implicitly removed.The "BaoPham\DynamoDb\DynamoDbQueryBuilder"
save()method uses the AWSputItem()instead of theupdateItem()when the record exists.Schema
GSI with a limited number of fields
Version info