DynamoDB Athena Failed to get metadata for table

Hi all, I plan to display DDB data on Quick Sight, through Athena. So I created a data source and am using the AWS default connector Lambda.
Here are my 3 DDB tables:


and I deploy the lambda successfully.
Here is the error that shows on Athena:
Failed to get metadata for table (cellobservations) from lambda function due to java.lang.RuntimeException: com.amazonaws.services.lambda.invoke.LambdaFunctionException: Requested resource not found (Service: DynamoDb, Status Code: 400, Request ID: 254N3QF9Q9AUSMBLONAHKD6N3FVV4KQNSO5AEMVJF66Q9ASUAAJG)

Has anyone gotten the same? Note that the region is N. Virginia, for every resource.
Thanks

Hi @ErmannoAttardo

Welcome to the Quick Sight community!

Please try the steps below to help troubleshoot and resolve this error.

  • Ensure that the DynamoDB table (cellobservations, events and global_mapping) is in the same AWS region (us-east-1 for N. Virginia) as your Athena and Lambda function. This is a common issue when regions mismatch.
  • Double-check the table name specified in the Lambda function. Ensure that it matches exactly with the DynamoDB table name (cellobservations, events and global_mapping ), including correct case sensitivity and any special characters.
  • Make sure that the Lambda function’s IAM role has sufficient permissions to access the DynamoDB table.
  • If your Lambda function is running inside a VPC, make sure that it has appropriate access to the DynamoDB endpoints (since DynamoDB is an AWS-managed service that may need proper VPC configurations).
  • When creating the Athena table to access the DynamoDB data, ensure that you have the correct schema definition and try to query the data in the Athena query editor to ensure that the Athena and DynamoDB connection setup is working fine.

Please refer to the below documentation this might be helpful for you.

1 Like

Hi @Xclipse , thanks for your answer.
The lambda is not my own, but the default one built and authored by AWS that should be plug-and-play. It’s called serverlessrepo-AthenaDynamoDBConnector. I was following this tutorial https://www.youtube.com/watch?v=R0OY_R61rG4
The region matches.
The table name mismatches, because CellObservations (name in DDB), is not cellobservations (name detected, correctly, by the AWS Lambda). In the video tutorial, this different capitalization is normal and makes no difference.
I tried attaching a full access policy to the lambda role (also used by Athena) and it made no difference.
Again, as the lambda was authored by AWS, it has no VPC and I have no visibility into it.
Anything else I could try?
Thanks

Hi @ErmannoAttardo

Sorry, I’m out of ideas. AWS Support would be able to check the logs and help you resolve the issue. I would recommend filing a case with AWS Support, where they can dive into the details and provide further assistance. Here are the steps to open a support case. If your company has someone who manages your AWS account, you might not have direct access to AWS Support and will need to raise an internal ticket to your IT team or whomever manages your AWS account. They should be able to open an AWS Support case on your behalf. Hope this helps!

Hi @ErmannoAttardo

It’s been a while since we last heard from you. If you have any further questions, please let us know how we can assist you.

If we don’t hear back within the next 3 business days, we’ll proceed with closing this topic.

Thank you!

Hi @ErmannoAttardo,
Since we haven’t heard back, I’ll go ahead and close out this topic. However, if you have any additional questions, feel free to create a new post in the community and link this discussion for relevant information if needed.

Thank you!