-
-
Notifications
You must be signed in to change notification settings - Fork 349
Closed
Description
Type: Feature
Is your feature request related to a problem? Please describe.
Is there a way to use a condition expression with DynamoDbOperations
for inserting data, or do I need to create a separate implementation of DynamoDbTable
, or should I just utilize the DynamoDbClient
?
Describe the solution you'd like
Perhaps we can create another method and call it like this.
var conditionalCheck = new ConditionalCheck();
conditionalCheck.setExpression(expression);
dynamoDbOperations.save(entity, conditionalCheck);
Describe alternatives you've considered
I created an implementation using DynamoDbClient
, and it worked.
val putItemRequest = PutItemRequest.builder()
.tableName(tableName)
.item(item)
.conditionExpression("attribute_not_exists(my_sk)")
.build();
dynamoDbClient.putItem(putItemRequest);
magnuspedro, arielsapatelli and PremSPatel
Metadata
Metadata
Assignees
Labels
No labels