I have a MYSQL database table called ‘wp_quotes’ with a field that contains a column called ‘media’ like below.
‘wp_quotes’ table
‘media’ – this column shows ‘1’ or ‘2’ (the ID number) depending on what the user has selected on the form.
I have another table called ‘wp_quote_forms_fields_values’ that assigns this ID a value – either ‘CD’ or ‘DVD’
‘wp_quote_forms_fields_values’ table
ID 1 has value of ‘CD’
ID 2 has value of ‘DVD’
When i run a query (to export a file), how can i get the media column to show ‘CD’ or ‘DVD’ instead of ‘1’ or ‘2’.
You would need to join to the table that has the descriptions, like so: