unemployment Posted April 20, 2011 Share Posted April 20, 2011 this is part of my union all. I can figure out why it's not a unique table name according to mysql UNION ALL ( SELECT `user_actions`.`user_id`, `user_actions`.`action_id`, UNIX_TIMESTAMP(`user_actions`.`time`) AS `approve_date`, `user_actions`.`details` FROM `user_actions` INNER JOIN partners ON partners.friend_id = user_actions.user_id AND partners.approved = 1 INNER JOIN partners ON partners.user_id = user_actions user_actions2.user_id AND partners.approved = 1 WHERE user_actions.user_id = ${uid} ) Link to comment https://forums.phpfreaks.com/topic/234290-not-unique-table-name/ Share on other sites More sharing options...
mikosiko Posted April 20, 2011 Share Posted April 20, 2011 so you don't see nothing wrong with this? INNER JOIN partners ON partners.friend_id = user_actions.user_id AND partners.approved = 1 INNER JOIN partners ON partners.user_id = user_actions user_actions2.user_id AND partners.approved = 1 use aliases for each one. Link to comment https://forums.phpfreaks.com/topic/234290-not-unique-table-name/#findComment-1204161 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.