Friday, August 30, 2013

Could not perform FindAll() for (Model) using ActiveRecordBase in Castle.ActiveRecord ORM

When running a simple mvc project, I encountered an error which states the Model.FindAll() could not be performed. Model is a class that maps to a database table. After tracing my codes, I found out that I have mispelled the database name in my web.config as specified below:
 <add key="connection.connection_string" value="Data Source=MyComputerStation\SQLEXPRESS;AttachDbFilename=|DataDirectory|\Blogs.mdf;Integrated Security=True;User Instance=True"/>  
What I did was change the database name from Blogs to Blog.

That's it! :)