Welcome Guest, Not a member yet? Register   Sign In
join with multiple conditions
#1

[eluser]bkarat[/eluser]
Hi !

I am new to CodeIgniter. The following query style is working fine in CodeIgniter:

$query=$this->db->query("Select b.INVCODE, b.INVNAME, b.LESSTYPE, a.PROPOSEDAMT, a.INVAMT
from STD b left outer join EMP a
on (b.INVCODE=a.INVCODE) and (a.FINSHORT='$finyear') and
(a.EMPCODE='$user')");

I am not getting the exact syntax to put this in Active Record style. When I use the last two conditions in a where clause, the result is not correct.

Thanks in advance.

With regards,
Bala


Messages In This Thread
join with multiple conditions - by El Forum - 02-24-2009, 11:43 PM
join with multiple conditions - by El Forum - 02-24-2009, 11:53 PM
join with multiple conditions - by El Forum - 02-25-2009, 12:25 AM
join with multiple conditions - by El Forum - 02-25-2009, 12:27 AM
join with multiple conditions - by El Forum - 02-25-2009, 12:38 AM
join with multiple conditions - by El Forum - 03-25-2009, 04:08 PM
join with multiple conditions - by El Forum - 03-25-2009, 04:21 PM
join with multiple conditions - by El Forum - 03-25-2009, 08:09 PM
join with multiple conditions - by El Forum - 03-25-2009, 08:16 PM



Theme © iAndrew 2016 - Forum software by © MyBB