在此代码中,如何才能得到结果只有数据具有特定item_id
,比如item_id = 3
?sql:结果只是具有特定item_id的数据
$articles = $dbRead->select()
->from('articles', array('article_id', 'name', 'item_id'))
->joinUsing('items', 'item_id', array('item_name'))
->order(array('updated DESC'));
您使用的框架?你将如何在你的查询中应用WHERE子句?我假设你有一个叫做'where'的方法?你能告诉我们这个定义吗? – 2014-10-10 10:13:03
是的,Zend和Zend_Paginator,但我是非常非常新手和WHERE不工作 – dAN 2014-10-10 10:56:23