Scriptbaker
SCRIPTBAKERAI & Software Engineering
Yii

Table 'DATEBASE_NAME.AuthAssignment' doesn't exist

<p>If you have used Rights module for RBAC in your Yii application and you deploy it on Linux based server, you may encounter this error.</p>

· 5 min read

Problem:
If you have used Rights module for RBAC in your Yii application and you deploy it on Linux based server, you may encounter this error.

Table ‘DATEBASE_NAME.AuthAssignment’ doesn’t exist

Cause of the problem:

This is because your tables names are in lowercase but in code they are being referred with different capitalization, Linux is case sensitive so it treats authassignment and AuthAssignment differently.

Solution:

In your root/protected/config/main.php specify exactly the same table names as they appear in your database.

 'components'=>array( 'authManager'=>array( 'defaultRoles'=>array('guest'), 'class'=>'RDbAuthManager', 'assignmentTable'=>'authassignment', 'itemTable'=>'authitem', 'rightsTable'=>'rights', 'itemChildTable'=>'authitemchild', ), 

S

Scriptbaker Editorial Team

The Scriptbaker editorial team comprises engineers, AI specialists, and digital strategists based in Dubai and Rawalpindi. We write about software development, artificial intelligence, and digital transformation to help organisations build better products. Learn more about us →