0

I need to do a multiple on clause on a left join query using codeigniter active record. I write this code:

$this->db->join('table1', 'table1.col1 = table2.id', 'left');
$this->db->where_not_in('table.col2', $list);

by doing this codeigniter add where not in clause, while I need to add a ON clause, related to the left join. If it's possible I would like to use active records.

pindol
  • 2,110
  • 6
  • 35
  • 52

1 Answers1

1
$this->db->join('table1', 'table1.col1 = table2.id AND col2 NOT IN ('.implode(',', $list).')', 'left');
pindol
  • 2,110
  • 6
  • 35
  • 52