Coding Cheatsheets - Learn web development code and tutorials for Software developers which will helps you in project. Get help on JavaScript, PHP, XML, and more.

Post Page Advertisement [Top]

Join in codeigniter

Join 3 tables by codeigniter

$query = ee()->db->select('b.id,b.rec_date,b.status,b.member_id, b.merchant_name, b.order_number, b.shipping_company, b.tracking_number,b.optional_service, b.inspected, c.first_name, c.last_name, c.mailbox_number,d.group_title as membership')
->from('exp_incoming_order b')
->order_by('b.id','desc')
->join('exp_members c', 'b.member_id=c.member_id and '.$whereCond)
->join('exp_member_groups d', 'd.group_id=c.group_id')
->limit($this->perpage, $rownum)
->get();

No comments:

Post a Comment

Bottom Ad [Post Page]