isao otika Mon Jun 10 08:46:02 -0400 2013

Subject: PHP activerecord exception : Base table or view not found

I am trying out php active record, it's a great ORM, however I am at a standstill.

I have looked around google, blogs, phpactiverecord documentation as well as statckoverflow for days but have not been able to come across a suitable solution to this problem.

I am able to carry out the basic CRUD (insert,fetch, modify and delete) operations however as soon as i validate an object property using a static $validates_uniqueness_of filter, i get

Fatal error: Uncaught exception 'ActiveRecord\DatabaseException'

With message

exception 'PDOException' with message 'SQLSTATE[42S02]: Base table or view not found: 1146 Table 'test_ar.models' doesn't exist' in C:\wamp\www\test_AR\AR\lib\Connection.php on line 325

Here is the code i used in full.