I have three tables;
user table
id first_name last_name country
2 John Doe USA
3 Jimmy Biglips FRA
user_meta (metadata) table
user_id meta_key meta_value
2 phone 3333
2 rating Good
3 phone 7777
3 rating Bad
country table
country_id country country_fullname
1 USA United States of America
2 FRA France
I need to query by "rating" (e.g. "good") and return the result set as;
id first_name last_name phone rating country country_fullname
2 John Doe 33333 Good USA United States of America
Because the user_meta table has multiple rows that corresponds to a member in the user table, I was having trouble returning a combined set of values in one row.
Thank you.