I added a new column "features" to the site table and regenerated the models using Doctrine.
This code is causing an error:
$siteTable = Doctrine_Core::getTable("Site");
$site = $siteTable->findOneByName("site"); // this line is throwing an exception
Exception:
Unknown column "s.features" in field list.....
I checked the database and it contains the field, I also checked the Site model and the table definition contains the column information. The primary key of all tables is id
.
Also in the line which throws the exception I am not using the newly added column. If I remove the column from the table definition of the site object then the above code works...
This error is happening to any table when I add a new column and regenerate the models from it.
Do you checked the generated Base Table Classes ? Should be BaseSite.class.php
./doctrine build-all
should fix the Problem.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With