I have a dynamo db schema lets say goes like this
const team = new dynamoose.Schema(
{
bitbucketDetails: [
{
id: {
type: String,
required: true,
},
repository: {
type: String,
},
},
],
})
I wanted to search for an item having lets say particular repository "abc". how can i search that?
so far i tried something like team.scan({ bitbucketDetails: { contains:"abc" }}).all().exec() but keep saying ValidationException: One or more parameter values were invalid: ComparisonOperator CONTAINS is not valid for M AttributeValue type.
Please help!!
You are looking for the value in bitbucketDetails, but you want to look in bitbucketDetails.repository.