Hi there,
I am having one issue while fetching details from related tables.
I have two tables having column named as user.
So while fetching details from first table,I have
$criteria->with = array(‘table2’ => array(
'select' => array(
'user','date'
)
),
);
and to check the user column from first table itself I have:
$criteria->compare(‘user’, ‘Active’,true);
Now, this gives me an error for column ambiguity. I tried adding modelname to compare criteria as:
$criteria->compare(‘FirstModel.user’, ‘Active’,true);,
but it didn’t solve the issue.
Any help is appreciated.
Thanks in advance.