$endsWith

Filter records where a column’s value ends with a specified suffix. The $endsWith method is used to retrieve entries that match a given string at the end, making it useful for filtering based on the ending of text fields.

await Member.$search({
    $where: {
        username: {
            $endsWith: 'five'
        }
    }
});

Last updated