AWS DynamoDB query failed due to attribute having certain characters

0 votes
data = table.query(KeyConditionExpression = Key('id').eq('fasfas'),
                   FilterExpression=Attr(u'Absolute humidity[g/kg].3').eq(1))

Error:

ClientError: An error occurred (ValidationException) when calling the Query operation: Invalid FilterExpression: Syntax error; token: "humidity", near: "Absolute humidity ["

How can I make it work using boto3 as it works fine on website?

P.S. it also doens't work with underscores.

Oct 15, 2018 in AWS by findingbugs
• 4,750 points
816 views

1 answer to this question.

0 votes

your parameter is not matching the datatype or a required parameter is missing such as range and hash key.

For more details you can go through the documentation

https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/Programming.Errors.html

answered Oct 15, 2018 by Priyaj
• 56,900 points

Related Questions In AWS

0 votes
1 answer

How to set-up DynamoDB trigger using AWS Lambda?

Well this code worked for me. You ...READ MORE

answered Aug 20, 2018 in AWS by Archana
• 4,090 points
695 views
0 votes
1 answer
0 votes
1 answer

While connectig to EMR Cluster AWS EMR Automated Failed

Doing that amount of work wont be ...READ MORE

answered Nov 2, 2018 in AWS by Priyaj
• 56,900 points
81 views
0 votes
1 answer

Updating an attribute in AWS DynamoDB

Unfortunately, it can't be achieved in a ...READ MORE

answered Nov 2, 2018 in AWS by Archana
• 5,560 points
151 views
0 votes
1 answer

Import my AWS credentials using python script

Using AWS Cli  Configure your IAM user then ...READ MORE

answered Nov 16, 2018 in AWS by Jino
• 5,560 points
453 views
0 votes
1 answer

AWS S3 uploading hidden files by default

versioning is enabled in your bucket. docs.aws.amazon.com/AmazonS3/latest/user-guide/….... the ...READ MORE

answered Oct 4, 2018 in AWS by Priyaj
• 56,900 points
290 views
0 votes
1 answer

Pass account id of an AWS sub account using a variable as an argument in CloudWatch Alarm Actions with python (boto3)?

Python String and Integer concatenation >>> print("arn:aws:swf:us-east-2:{0}:action/actions/AWS_EC2.InstanceId.Stop/1.0".format(acccnum)) arn:aws:swf:us-east-2:12312312312312:action/actions/AWS_EC2.InstanceId.Stop/1.0 >>> print("arn:aws:swf:us-east-2:" ...READ MORE

answered Oct 5, 2018 in AWS by Priyaj
• 56,900 points
161 views
0 votes
1 answer

How to decrypt the encrypted S3 file using aws-encryption-cli --decrypt

Use command : aws s3 presign s3://mybucket/abc_count.png you get ...READ MORE

answered Oct 22, 2018 in AWS by Priyaj
• 56,900 points
654 views
0 votes
1 answer
+1 vote
1 answer