You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The misunderstanding was solved in IRC by talking to @ericj. Cake will not inspect into datasource configurations for resolving possible joins. You need to either use the same datasource or set the table name correctly to include the database name
In cakephp 2.2.x, we can have automatic join work for cross databases with a simple patch:
"lib/Model/Datasource/DboSource.php function read()
if ($model->useDbConfig === $linkModel->useDbConfig) {
...
to
if ($model->useDbConfig === $linkModel->useDbConfig || $type=='belongsTo') {
...
But in recent 2.5.x, the read function seems have some changes,
I was wondering how to make the cross database auto join for belongsTo ?
The text was updated successfully, but these errors were encountered: