CDbException:CDbCommand failed to execute the SQL statement: SQLSTATE[42S02]:...

I am using the latest yii framework yii-1.1.10.r3566.tar.gz

I did not have problems in my developing setup (windows 7, latest XAMPP 1.7.7)

but when I deployed my webapp to remote site ( I am using justhost linux env … )

I got errors


CDbCommand failed to execute the SQL statement: SQLSTATE[42S02]: Base table or view not found: 1146 Table ‘XXXX_mts.AuthAssignment’ doesn’t exist

I searched this issue from the web , there were similar issues in the previous yii too… can not get solution …

did I do anything wrong …!

does anyone have good solutions …? thx

I believe it is a bug …


This is one of the most common error when changing from case insensitive OS like windows to a case sensitive OS like linux… check the case of your table it should be "AuthAssignment" - note the case.


I am looking into the function where I can use php’s strtolower function …to handle it …

anyone has any idea where should I added strtolower …


try to set this property to all lowercase -

you will probably need to do the same for


I run this SQL and it works just fine:

RENAME TABLE `authassignment` TO `AuthAssignment` ;

Thanks for this!

Sorted my errors out from ‘development using wamp on windows’ to going ‘live on a linux server’.

Used a a few capitalizations in rule components for table names.