[b]I have two tables :
Categories and CategoriesDescriptions
In CategoriesDescription there is a language_id column.
How do I retrieve data for a particular langauge_id ex: language_id =1
The following AR gives as error saying language_id not found.
$model = Categories::find()->with(
['CategoriesDescriptions'=> function($query) {$query->andWhere('language_id=1');}]
)->all()[/b]