> -----Original Message-----
> From: sqlalchemy@googlegroups.com 
> [mailto:sqlalch...@googlegroups.com] On Behalf Of 
> mhearne808[insert-at-sign-here]gmail[insert-dot-here]com
> Sent: 10 February 2009 19:13
> To: sqlalchemy
> Subject: [sqlalchemy] altering tables
> 

[snip]

> 
> I'd like to update the database (do the equivalent of an 'ALTER TABLE'
> SQL command) without destroying all of the data I already have.  How
> do I do this?
> 
> I have already tried using:
> metadata.create_all(engine,checkfirst=True)
> 
> which can handle _new_ tables being added, it seems, but doesn't seem
> to update the tables for which I have altered the definitions using
> the Table object.
> 
> I'm using SQLAlchemy '0.5.0beta3', with Python 2.5 on Mac OS X.
> 
> Thanks,
> 
> Mike
> 

You may like to have a look at the SQLAlchemy Migrate project:

http://code.google.com/p/sqlalchemy-migrate/

Hope that helps,

Simon

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email to 
sqlalchemy+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---

  • [sqlalchemy] alte... mhearne808[insert-at-sign-here]gmail[insert-dot-here]com
    • [sqlalchemy]... King Simon-NFHD78

Reply via email to