Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有三个表产品,具有相同创建日期列“创建”的事件。但是,如果任何用户向任何表格添加条目,则应从网页上的特定行显示详细信息。你能建议我吗,怎么做?
SELECT * FROM (SELECT col1, col2, date FROM table1 ORDER BY date DESC LIMIT 1 UNION SELECT col1, col2, date FROM table2 ORDER BY date DESC LIMIT 1 UNION SELECT col1, col2, date FROM table3 ORDER BY date DESC LIMIT 1) u ORDER BY date DESC LIMIT 1