I have a list with an identifier of type String. I want to scan DynamoDB and get a list of results with elements that DO NOT have these identifiers. But I can’t figure out how to type a filter expression. ReviewId is the primary key of a section of type String.
Map<String, AttributeValue> eav = new HashMap<>(); eav.put(":idFilter", new AttributeValue().withSS(idFilter)); DynamoDBScanExpression scanExp = new DynamoDBScanExpression() .withFilterExpression("ReviewId <> (:idFilter)") .withExpressionAttributeValues(eav);
The above filter expression is valid, but it still always returns elements with an identifier in the list. I also tried to include the word inbefore and after the statement <>.
in
<>
, , ExpressionAttributeValues :reviewId1, :reviewId2, :reviewId3.
ExpressionAttributeValues
:reviewId1, :reviewId2, :reviewId3
FilterExpression: "NOT ReviewId in (:reviewId1, :reviewId2, :reviewId3)"
: -
, idFilter SET LIST DynamoDB.
idFilter
Source: https://habr.com/ru/post/1672148/More articles:Visual Studio 2017 висит за 2, 3 минуты до начала сборки - buildHadoop (HDFS) - file versioning - version-controlHow to create two projects, but not two modules in one workspace in IntelliJ IDEA? - javareading files on Google Cloud - google-cloud-mlDownload numpy array in google-cloud-ml job - pythonHide Service Passwords in Cake Build - c #How to read gz compressed file using pyspark - pythonWorking with a large gzip file in Spark - gzipНастройка HTTPS для Express и Nginx - javascriptHow to add second line of labels for axes - pythonAll Articles