Bladephp: Now with 7+ codeigniter, php, and laravel project 7+ php project From $18/Year From Rs. 1000/Year

Join Query in Codeigniter

by
Category:codeigniter
codeigniter mysql
Join Query in Codeigniter

This tutorial will help you to learn join query using php codeigniter. Table joins are essential part in application development while displaying the records from multiple tables.

Let’s create a join method in codeigniter

$this->db->select('tbl_order.*,tbl_user.fullname');
$this->db->from('tbl_order');
$this->db->join('tbl_user', 'tbl_user.id = tbl_order.user_id');
$query = $this->db->get();
return $query->result();

0 Comments


Html code work in comment box


Related Post