php - sql: result be only data with a specific item_id -
php - sql: result be only data with a specific item_id -
how can, in code, result info specific item_id
item_id = 3
?
$articles = $dbread->select() ->from('articles', array('article_id', 'name', 'item_id')) ->joinusing('items', 'item_id', array('item_name')) ->order(array('updated desc'));
try :
$articles = $dbread->select() ->from('articles', array('article_id', 'name', 'item_id')) ->joinusing('items', 'item_id', array('item_name'))->where("items.item_id = 3") ->order(array('updated desc'));
php sql
Comments
Post a Comment