Search on dataset not working

I’m struggling to resolve this issue. I have a search set up to search two fields in a dataset. If, for example, I search for Bush, the repeater linked to the dataset shows the correct answer. If I search for Bethel, again the repeater shows the correct answer. If I enter Bush Bethel (or vice versa) then the repeater doesn’t show anything.

Could anyone tell me where I’m going wrong?


import wixData from wix-data;

let debounceTimer
function update() {
if (debounceTimer) {
debounceTimer = undefined;
debounceTimer = setTimeout(() => {
}, 1000);

export function search_click(event) {

function filter() {
    .contains("content", $w("#filterText").value)
    .contains("keyword", $w("#filterText").value)
export function clear_click(event) {
$w("#filterText").value = "";


Im guessing you will need another input element to do this, i have the same code virtually on my website with two elements set up, and in the code where it says .or change it to .and, if you still struggle afterwards i can send you a snippet of my working code

Thanks for your reply Stevo.

The search works perfectly on searching on both columns - if I have a word in both content and keywords it returns the search on both columns correctly.

However it’s when I’m putting in more than one word and it’s not in the exact order is in the database that I have a problem.


Content - 1st Vermont at Big Bethel by Erick Bush.
Search for Bethel - content returned correctly
Search for Bush - content returned correctly
Search for 1st Vermont at Big Bethel - content returned correctly
Search for Bush Bethel (or Bethel Bush) - no search returned

Any help you can give thanks so much!