The situation I am about to describe happened while I was working on a search engine for bibliographic data but I am transposing it for the car dealer's system.
When we have to migrate data from a pre-existing system into our newly-born data structure, we might encounter data that was formatted in a special way. For example, a list of possible colors for a car model could be expressed as a series of color codes, separated by semi-colons:
Users of the pre-existing system are comfortable with this method of entering data in this format, and in the case I experienced, users refused to let go of this way of entering data—and they had direct access to the MySQL tables. From a developer's perspective, however, such format makes the task of query generation more complex. Finding the 1A6
color involves splitting the data element, and avoiding the 2T1A65
data element, which also has the 1A6
string.
A proper structure for this case implies getting rid of the...