0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

テーブルの結合に関する覚え書き

Posted at

LEFT OUTER JOINしたくて、下記ブログを参照しながらやってみた。

LEFT OUTER JOINする

・・・なるほど!
でもうまくいかない・・・なんでーなんでー

試行錯誤した結果、やっとできました

company.rb
includes(:apps_companies).
    where(AppsCompany.arel_table[:app_id].eq(nil))

ってincludesの中身は複数形にしないといけなかったのかー(ヽ´ω`)

修行します。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?