> sql = 'SELECT news., news_archive. FROM news,news_archive WHERE news.headline LIKE :keyword AND news_archive.headline LIKE :keyword ORDER BY news.date AND news_archive.date DESC';
sql = 'SELECT news.*, news_archive.* FROM news,news_archive WHERE news.headline LIKE :keyword AND news_archive.headline LIKE :keyword ORDER BY news.date AND news_archive.date DESC';
但重复上市消息?请帮助我。
有2个表,news和archive news。 我想在 2 个表中搜索新闻标题 两个表有一个新闻标题列。
SELECT table1.*,table2.* FROM table1,table2 WHERE tabel1.colon1 LIKE %search% AND tabel2.colon2 LIKE %search% ORDER BY tabel2.date AND tabel2.date DESC
sql = 'SELECT news.news_title_column, news_archive.news_title_column FROM news,news_archive WHERE news.headline LIKE :keyword AND news_archive.headline LIKE :keyword ORDER BY news.date AND news_archive.date DESC';