I'm pretty sure this can be done, but after searching MariaDB docs, I'm not sure how.
I would like to return all items based on a join_extract
search (I think).
These are the values to return from the vendor_certs
table:
+----+-------------------+
| id | cert |
+----+-------------------+
| 1 | Organic |
| 2 | Kosher |
| 5 | BRC |
| 6 | SQF |
| 7 | Halal |
| 8 | ISO |
| 9 | EPA |
| 10 | NSF |
| 11 | Walmart Certified |
| 12 | Target Certified |
| 13 | FDA |
+----+-------------------+
Based on a SELECT
from the vendor_key_value
table:
+----+-----------+--------------+------------+
| id | vendor_id | meta_key | meta_value |
+----+-----------+--------------+------------+
| 28 | 12 | vendor_certs | ["9","13"] |
+----+-----------+--------------+------------+
I'm looking for the output to be:
EPA, FDA
Any help would be great. Thanks.