I need to store set value in MySQL column. I completely like the build-in SET
type, but it seems that FIND_IN_SET()
function requires table scan which is bad.
It seems that SET
uses binary values under the hood. If I use binary value to represent a set, for example for a set of four elements it could be something like this:
0100 0101 0110 etc
How I can store it (which type), how to query and take advantage of indexes?
P.S. I indeed need a solution without separate linking table, something similar to SET.
Thanks in advance!