I'm having a strange issue. When I use this query:
SELECT count(VID) AS total, UID FROM video WHERE channel LIKE '%|22|%' GROUP BY UID ORDER BY total DESC LIMIT 5
Everything works fine. But when I duplicate the "channel" table and call the new table "channel_cl", then run the exact same query, but with the new table name:
SELECT count(VID) AS total, UID FROM video WHERE channel_cl LIKE '%|22|%' GROUP BY UID ORDER BY total DESC LIMIT 5
I receive this error:
Unknown column 'channel_cl' in 'where clause'
I don't understand why the query is working on the original table, but not after I duplicate the table. Does anyone have any ideas?