After doing a lot of searching and reading I think I came up empty on a subselect I wanted to do in MySQL. Here’s what I was trying to do:
1 record 1
2 record 2
This is what I was trying to accomplish:
SELECT * FROM table1 WHERE id IN (SELECT * FROM table2 WHERE rec = val1);
I know there’s a million ways around this, with the correct 2 table syntax, a RIGHT JOIN, etc., but I was in this predicament where I just wanted to add to the original full select of SELECT * FROM table1.