Top "Models" questions

Part of the MVC pattern, the Model manages the behaviour and data of the application.

Remove Model and Table so can start again in Rails

I created a model for comments at the start of a project, but have now come to the realisation I …

ruby-on-rails models polymorphic-associations rails-migrations destroy
Should I avoid multi-table (concrete) inheritance in Django by any means?

Many experienced developers recommend against using Django multi-table inheritance because of its poor performance: Django gotcha: concrete inheritance by Jacob …

django inheritance models multi-table-inheritance concrete-inheritance
Overriding default_scope in Rails

In my Post.rb model, I have default_scope :conditions => {:deleted => 'false'} But if I try to run …

ruby-on-rails models default-scope
CakePHP: Access Model in other Model / in app_model.php for Validation of Banknumber

I am wondering how I could use data from a Model B while I am validating Model A, here to …

php cakephp cakephp-1.3 models
How do Django Fixtures handle ManyToManyFields?

I'm trying to load in around 30k xml files from clinicaltrials.gov into a mySQL database, and the way I …

django many-to-many models fixtures
How to use Update query in Flask Peewee?

Hi I am using Flask Peewee and trying to update merchant_details model but it is not working. Following is …

python flask models flask-wtforms peewee
getting model data to a view backbone.js

I am trying to understand the relationship between a model and a view. I've tried building a model and view …

backbone.js models backbone-views
How to manage Single Table Inheritance within Doctrine 2?

I have comments and articles, both are votable. So, basically I've three entities, Article, Comment and Vote. After some reading …

php models doctrine-orm single-table-inheritance
Codeigniter - return my model object instead of stdClass Object

Not sure the best way of phrasing this so bear with me. Within Codeigniter I can return a record set …

php codeigniter codeigniter-2 models stdclass