I have a key starting with underscore and don't know how to query it
aws dynamodb query \
--table-name mytable \
--key-condition-expression '_mykey=:xxx' \
--expression-attribute-values '{ ":xxx": {"S": "somevalue"}}'
An error occurred (ValidationException) when calling the Query operation: Invalid KeyConditionExpression: Syntax error; token: "_", near: "_mykey"
Can I escape it somehow? I tried "/_mykey"
and "\_mykey"
but doesn't work.
this might be the most awful user experience ive ever had with a tool
aws dynamodb query \
--table-name mytable \
--projection-expression "#aaa" \
--expression-attribute-names '{ "#aaa": "_id" }' \
--key-condition-expression "#aaa=:bbb" \
--expression-attribute-values '{ ":bbb": {"S": "somevalue"}}'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With