knex.from('users').innerJoin('accounts', 'users.id', 'accounts.user_id') Outputs: select * from `users` inner join `accounts` on `users`.`id` = `accounts`.`user_id`