On Sat, 4 Feb 2006 20:20:42 +0000, James Adam wrote:

> The only situation where the user table would be deleted given a
> standard login/user engine setup would be if *you* ran:
> 
>   rake engine_migrate ENGINE=login_engine VERSION=0

Ah, ok.  I haven't used migrations before, so I didn't know what would have
happened if, say, I'd had a pre-existing User table, and used migrations to
add the new fields for LoginEngine and UserEngine.  Looking more closely,
I'm guessing I would have had an error - if my table already had a schema
version, then 001_initial_schema wouldn't have run, and if it had, it's
only creating tables, not adding fields... 

This does make me think that some future version of Engines might want to
handle just such a case - an engine that either creates its own table, or
adds fields to an existing table.  But that might be tricky since you can't
version parts of a table.  Ah well.  I guess that, in turn, depends on
fancier inheritance in Rails.

Jay Levitt

_______________________________________________
engine-users mailing list
[email protected]
http://lists.rails-engines.org/listinfo.cgi/engine-users-rails-engines.org

Reply via email to