[eluser]Kyle Johnson[/eluser]
I think you may have to do something like this:
Code:
$sql = "SELECT TOP 1 id, status, name FROM user WHERE id=3"; // specific user
$query1 = $this->db->query($sql);
$sql = "SELECT * FROM some_table WHERE id = ? AND status = ? AND author = ?"; // query_binding
$query2 = $this->db->query($sql, $query1->row_array()); // query1 returns only a single value
I'm not sure if this will work.
Code:
$sql = "SELECT TOP 15 id, status, name FROM user WHERE status='live'"; // 15 users
$query1 = $this->db->query($sql);
$sql = "SELECT * FROM some_table WHERE id = ? AND status = ? AND author = ?"; // query_binding
$query2 = $this->db->query($sql, $query1->result_array()); // not sure if this will work