Hi,
i am beginer to codeignitor,i know how to write basic active queries in CI.
i want to know how to write a query(having multiple conditions,double parentheses) in which supports CI.
query is:
$query="SELECT * FROM apply_special_leave
WHERE ((from_date
<= '$dt1' AND '$dt1' <= to_date
) OR (from_date
between '$dt1' AND '$dt2')) AND user_id='$user_id' AND status!='2'";
thank you.