Error when querying WIX blog collection by tag

Hi.

On my WIX site (I’m using WIX Studio) I have a blog that I have created by installing the WIX blog app. In this blog, I have created blog posts that I have tagged with different tag names.

I would like users to be able to filter the list of blog posts on a page but not using the standard Tag Cloud functionality. Instead, I only want them to be able to filter by specific tags.

I have a repeater linked to a dataset on one of my pages. The Daset is linked to the Post (Blog) collection. I would like users to be able to filter blog post records in this dataset by selecting a tag value from a dropdown list. This dropdown list only has specific tags - not all tags. The repeater should only show blog posts that have the tag the user has selected.

I believe in code you refer to the Post collection as “Blog/Posts”.
I have tried the following code.

export function dropdownCategory_change_1(event) {

let dropDownVal=$w( "#dropdownCategory" ).value;
    wixData.query( "Blog/Posts" )
    
    .eq("tags",dropDownVal)
            
    .find() 
    .then(results => { 
        $w( "#repeater7" ).data = results.items; 
        console.log(results.items)

        console.log("category: ") + dropDownVal;
    })
.catch((err) => {
            console.log(err);




        })

}

But when I select a tag from, the dropdown list I get the the following error message:

Error: WDE0080: Validation failed

I hope someone can help me solve this.

Many thanks

Mark

Hi Mark. What value did you get from your console log? This can help diagnose where the error is coming from

Hi.

Thanks for your reply. Unfortunately, it doesn’t give a value in the console log. It just says on the last line, Error: WDE0080: Validation failed.

Thanks

Mark