James Bennett wrote:
> 
> Also, consider this: your original argument was that inferring models
> from the database is useful because then you can "get an admin
> interface up-and-running just by pointing to a database". But
> regardless of whather the model is specified in Python or inferred
> from the database, at some point it has to be specified -- for that
> database to exist and have the tables it does, someone must have
> written and executed some SQL. Now, probably the overwhelming majority
> of new developers adopting Django are not going to be integrating with
> legacy databases, and in any case they wouldn't do it by pointing at
> their production DB. So one way or another, the first step is *always*
> going to be specifying the model. What usability gain, then, is there
> in making this specification vary depending on the inconsistencies and
> idiosyncracies of different database systems, when right now we have a
> perfectly good way of specifying models which has one and only one
> syntax that a developer must learn?
> 

Another reason that I really dislike generating a model from a database:
people have to learn the exact situations in which it will work and and
won't work. Eg what will it do with field types it doesn't know about,
what if you use some nonstandard half-oo features like postgres has...

I really don't like the idea of "just" pointing things at an existing
database. I think the current "introspect my db and tell me what you
think" thing is much more reasonable.

Reply via email to