Re: Simple Select (You'd think)

2004-04-18 Thread Michael Stassen
Of course. My fault. item_id is in both tables, so it's ambiguous unless you specify. Glad you figured it out. Michael Richard Williams wrote: Thank you very much that worked great except I had to make it "select new.item_id". Richard Subqueries are supported staring with mysql 4.1. I'

Re: Simple Select (You'd think)

2004-04-18 Thread Richard Williams
Thank you very much that worked great except I had to make it "select new.item_id". Richard Subqueries are supported staring with mysql 4.1. I'm guessing you have an earlier version. You can rewrite your query as a join, though. SELECT item_id FROM new LEFT JOIN old using (item_id)

Re: Simple Select (You'd think)

2004-04-18 Thread Michael Stassen
Subqueries are supported staring with mysql 4.1. I'm guessing you have an earlier version. You can rewrite your query as a join, though. SELECT item_id FROM new LEFT JOIN old using (item_id) WHERE old.item_id IS NULL; See the manual

Simple Select (You'd think)

2004-04-18 Thread Richard Williams
This is my first post so forgive me if I put it in the wrong place or screwed it up in some way. I have two tables, "new" and "old" and I want to show all rows in one table that do not appear in the other table. I tried this select from the manual section "14.1.8.3 Subqueries with ANY, IN, and