I have a data set that I want to scan and filter out.
I want to filter out these two values in my table:
- F7138546-5819-4534-98F8-959A2B8DC06E
- DFG83855-FF86-440D-8CA0-15A2709A58E8
Is it right to enter the two data in attribute.SS? Is there another way for me to achieve this function? Please help me cause I have been thinking about this for a very long time. The criteria should be or
, that is, the hash key will not be value a or value b rather than neither a nor b.
AWSDynamoDBObjectMapper *objectMapper = [AWSDynamoDBObjectMapper defaultDynamoDBObjectMapper];
AWSDynamoDBScanExpression *scanExpression = [AWSDynamoDBScanExpression new];
scanExpression.exclusiveStartKey = self.lastEvaluatedKey;
scanExpression.limit = @20;
attribute.SS = @[@"F7138546-5819-4534-98F8-959A2B8DC06E",@"DFG83855-FF86-440D-8CA0-15A2709A58E8"];
AWSDynamoDBCondition *condition = [AWSDynamoDBCondition new];
condition.attributeValueList = @[attribute];
condition.comparisonOperator = AWSDynamoDBComparisonOperatorNE;
scanExpression.scanFilter = @{@"hashKey":condition};
return [[[objectMapper scan:[DDBTableRow class]
expression:scanExpression]
Thank you for that. Thank you again