Dear visitors of Stack Overflow,
I am building a research application in PHP where the user can enter it's own variables. These variables are often numerical. A text label can be attached to each numerical value to improve the readability of the data. That is, the records are displayed as:
Record1: Value0, Value1, Value1, Value3, Value2
Record2: ..
instead of:
Record1: 0, 1, 1, 3, 2
Record2: ..
In order to transform the numerical data to their label counterparts I would have to perform a great number of joins to the (same) table holding the textual representation (the label). My question is twofold:
- Will performing multiple joins to the same table (aliased) in MySQL impact the performance by much?
- What would be the best SQL syntax for such a join?
Of course I welcome any other suggestions!
I look forward to your answers!
Tom