I’ve got a problem and it seems some before me have had similar problems but I haven’t been able to find a working solution for me.
I’m currently building a mobile w
This will be very difficult to do if all you have is the dictionary. If you have the ability to make a new table or new columns, I would :
Create a table with a column for the word, plus 26 columns (one for each letter) Run a stored proc/backend process that counts the occurences of each letter in a word, and puts them into the appropriate column.
Then (ignoring wildcards) you can do
Select word from dictionary where tcount <=2 and ecount <=1 and scount <=1
for wildcards you could do and length <= number_of_letters
Actually always use the length clause, because you will then be able to index on it to improve performance.
Anything else is going to be exceptionally slow during the query