How to Recognize the Antipattern
Some questions like the following commonly indicate that the Poor Man’s Search Engine antipattern is being employed:
-
“How do I insert a variable in between two wildcards in a LIKE expression?”
The question usually comes up when the programmer wants to do a pattern-matching search using input from a user.
-
“How can I write a regular expression to check that a string contains multiple words, that the string doesn’t contain a certain word, or that the string contains any form of a given word?”
If a complex problem seems too hard to solve with a regular expression, it probably is.
-
“The search feature of our website has become unusably slow as we’ve added more documents to the database. What’s wrong?”
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access