php - Return all elements from list that don't have a record. (MYSQL) -
i have list of feeds:
('feed1', 'feed2', 'feed3')
i have table feeds
list of feeds, need find feeds in search list don't appear in database.
create table `feeds_filtered` ( `id` char(36) not null, `url` varchar(255) not null, ...... primary key (`id`) ) engine=myisam default charset=utf8;
for example feed1 , feed3 exist in table want feed 2 returned. please note: feeds table has feed4, feed5 etc don't want them returned either. feed2
i can write php script this, wondering if there easy way mysql?
thanks in adavnce!
you create temporary table, left join
, records rhs of join null
.
Comments
Post a Comment