When I log in to my site and I have the civicrm_group_roles
module enabled, I'm getting this generic error in the browser:
Error
The website encountered an unexpected error. Please try again later.
In the database log, I see this error message:
PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table
'singersin_drupal.singersin_combined.civicrm_group_roles_rules' doesn't exist:
SELECT r.name AS name, cgr.role_id AS role_id, cgr.group_id AS group_id FROM
{civicrm_group_roles_rules} cgr INNER JOIN {role} r ON r.rid=cgr.role_id; Array ( ) in
civicrm_group_roles_sync_roles() (line 821 of
/Users/ken/src/SIA/server275-site/sites/all/modules/civicrm/drupal/modules/civicrm_group_roles/civicrm_group_roles.module).
Note the table name singersin_drupal.singersin_combined.civicrm_group_roles_rules
- that's actually the Drupal database name, followed by the CiviCRM database name, followed by the table it's looking for. So I assume that somehow the {civicrm_group_roles_rules}
token is getting filled in wrong when the site has different databases for Drupal and CiviCRM.
I can work around this by disabling the civicrm_group_roles
module (drush dis civicrm_group_roles
).
I'm using:
- CiviCRM 5.32.2
- Drupal 7.76