$where = sql_in_select("column", "column", "tables", "id_parent = $id_parent")); // $where: column IN (3, 5, 7) if ($res = sql_select('column', 'another_table', $where)) { // ... }