From what I understand using tokenize with match all tokens currently forces a match of all tokens on the same key. Would it be possible to force a match of all tokens across any keys of a single match?
e.g.
{
title: "Old Man's War",
author: {
firstName: "John",
lastName: "Scalzi"
}
}
searching for Old War will match this record, but Old War John will not.
This would be useful in searches where you want two or more attributes of a record to match.
i.e.
{
jobtitle: 'Lawyer',
country: 'France'
},
{
jobtitle: 'Developer',
country: 'France'
}
There should be a way for a search to return only the first record when search for "lawyer france"
Interesting. Need think on this some more 馃槄.
This would be awesome! =)
Opens a lot of new possibilities!!
I've hit the same problem and am currently working around this limitation by using my own getFn which simply bangs all fields together into a single string ... this requires another hack, where I allow multiple fields to be specified in a single key, separated by ",". Yes, an ugly hack, but gets the job done.
Why do you think it's an ugly hack? That's something that could potentially become a feature.
One does not preclude the other... ;)
Show us the code!
One downside I see is that reporting hit ranges will not work, because these relate to the virtual combined item, not the real key items.
Could really use this feature for my current project! Would love to see it implemented.
This would be really helpful
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days
Most helpful comment
Interesting. Need think on this some more 馃槄.