function get_all_notification() { //get all notification based on the 'notification' table left join by 'membership' table
$this->db->select()->from('notification')->join('membership','membership.membership_id = notification.notif_id','left'); $notif = $this->db->get();
return $notif->result();
}
メンバーシップテーブルのフィールドを表示できません。codeigniterの左結合のアクティブレコードを使用して、2つの異なるテーブルのフィールドを表示するにはどうすればよいですか?
使用 –
:
グッドラックと楽しみコーディングがありますか? –
select()にメンバーシップの列名も入力する必要があります。select( 'notification。*、membership。*')と動作したら教えてください –