Selecting from multiple tables using ActiveRecord in CodeIgniter. Basics are the same as in query. You select multiple tables, relate tables and select the output fields.
Source code viewer
// Just an example $count = $this->db ->from('user') ->from('auth') ->where('auth.user_id = user.user_id') ->where('user.username', $user) ->where('auth.auth', do_hash($pass)) ->count_all_results(); Programming Language: PHP