Unanswered: Help collating multiple records from multiple tables into a single record
That is probably a horrible description of what I need.
What I have is a two tables, one that contains "field" information. This table was designed to allow a web site administrator a high level of configuration for collecting data.
The other table simply contains the values for these configurable fields:
user_id int(11) -> user data contained in another table
field_id int(10) -> ties to id field in previous table
Now what I want to do is create a tmp table based off of search criteria... but I want to collate the user data into a single record using the fieldcodes from the first table as columns. Because as you can imagine, if the admin has created 13 fields each user has 13 entries in the "values" table.
Can this be done with SQL or does it have to be done using multiple steps with a secondary processing language (in my case php)?