I'd like to know a good solution for converting a LEFT JOIN into a table/matrix.
For example, given this schema:
objects id (integer) name (string) attributes id (integer) object_id (integer) name (string) value (string)
And these values:
1,ball 2,box 1,1,colour,red 2,1,shape,sphere 3,1,material,rubber 4,2,colour,brown 5,2,shape,cube
I'd like to get this:
object_id | object_name | colour | shape | material 1 | ball | red | sphere | rubber 2 | box | brown | cube | NULL
Ideally this would be with an unknown number of attributes for each object, and be for MySQL without using stored procedures.