Predictive Search – a solution to search contains
Predictive search for Kinetic was originally searching “Contains” in the description or name.
When revision 2024.1 came out it was changed to “begins with” because that is what the Classic screens would do. After many discussions with support and non-with product managers the decision stuck. Epicor switch Kinetic 2024.1 do predictive search to “begins with”.
Frustrated, I came up with an approach that will search based on each word in the description.
First I took all spaces and replaced them with a “~”
Part | Description | TildeDesc |
---|---|---|
AS-036 | 6061-T6 ALS .036" x 48" x 144" | 6061~T6~ALS~.036"~x~48"~x~144" |
Then separated the words into Desc1, Desc2, …
Part | AS-036 |
---|---|
Description | 6061-T6 ALS .036" x 48" x 144" |
TildeDesc | 6061~T6~ALS~.036"~x~48"~x~144" |
Desc1 | 6061 |
Desc2 | T6 |
Desc3 | ALS |
Desc4 | .036" |
Desc5 | x |
Desc52 | 48" |
Desc7 | x |
Desc8 | 144" |
Desc9 | |
Desc10 |
Then using a UnionAll subquery setup a search subquery.
The search phrase is the description prefixed with each word so when you search you will find your parts. (or customers or suppliers)
Part | Desc1 | Description | search | Word |
---|---|---|---|---|
AS-036 | 6061 | 6061-T6 ALS .036" x 48" x 144" | 6061-6061-T6 ALS .036" x 48" x 144" | 1 |
AS-036 | T6 | 6061-T6 ALS .036" x 48" x 144" | T6-6061-T6 ALS .036" x 48" x 144" | 2 |
AS-036 | ALS | 6061-T6 ALS .036" x 48" x 144" | ALS-6061-T6 ALS .036" x 48" x 144" | 3 |
AS-036 | .036" | 6061-T6 ALS .036" x 48" x 144" | .036"-6061-T6 ALS .036" x 48" x 144" | 4 |
AS-036 | x | 6061-T6 ALS .036" x 48" x 144" | x-6061-T6 ALS .036" x 48" x 144" | 5 |
AS-036 | 48" | 6061-T6 ALS .036" x 48" x 144" | 48"-6061-T6 ALS .036" x 48" x 144" | 6 |
AS-036 | x | 6061-T6 ALS .036" x 48" x 144" | x-6061-T6 ALS .036" x 48" x 144" | 7 |
AS-036 | 144" | 6061-T6 ALS .036" x 48" x 144" | 144"-6061-T6 ALS .036" x 48" x 144" | 8 |
PartContains - 2024.1.baq (40.6 KB)