46 Commits

Author SHA1 Message Date
Jenkins
e20068490b Merge "Eradicate trailing whitespace" 2014-03-29 18:27:33 +00:00
Thomas Goirand
8d6ce64cd0 Use native quote attribute introduced in sqla 0.9
In SQLA 0.9 there is now a native .quote attribute on many objects.
Conditionally use this instead of the old method if the attribute
exists, to remove deprecation messages (and prepare for when the
other way will be fully removed).

Change-Id: I3c5fada13e044c1c4102acc0455226ce1524f2e2
2014-03-05 08:20:49 -05:00
Matt Riedemann
12a6bcfa8c Conditionally import ibmdb2/ibm_db_sa
Since ibm_db_sa is not part of sqlalchemy, we need to handle the
conditional import of the module in visitor.py so we don't get an
ImportError if ibm_db_sa is not available.

Closes-Bug: #1287229

Change-Id: Ida070b629ce3b9be727ae49973bb6a71543c1dcf
2014-03-04 10:12:40 -08:00
David Ripton
d6fbf12989 Eradicate trailing whitespace
Remove all trailing spaces and tabs in every file in the project.
People have editors configured to do this, which causes them to
accidentally make little whitespace changes in unrelated commits,
which makes those commits harder to review.  Better to fix them all
at once.

Change-Id: I17d89f55f41d8599e0ab1a31f646cd161289703e
2014-02-26 15:04:54 -05:00
Matt Riedemann
85317aead6 Add DB2 10.5 Support
This patch adds the initial support for DB2 10.5 to migrate. It
includes:

1. The dialect implementation for DB2.
2. The dialect registration with the visitor.
3. Code to parse the engine name in version.py.
4. A new dependency on ibm_db_sa in test-requirements.txt.
5. A connection string in test_db.cfg for ibm_db_sa.

Part of blueprint add-db2-support

Co-authored-by: Sheng Bo Hou <sbhou@cn.ibm.com>
Co-authored-by: Thuy Christenson <thuy@us.ibm.com>
Co-authored-by: Rahul Priyadarshi <rahul.priyadarshi@in.ibm.com>
Change-Id: I745ec615487b1b06c5d1a09ea316f376d66ee4c0
2014-02-17 07:17:31 -08:00
Jan Dittberner
a48190c006 merge e5bd2821eea8 from https://code.google.com/r/alyazdi-patches/
(fixes issue 125)
2011-10-28 12:25:22 +02:00
Jan Dittberner
3619347441 drop SQLAlchemy < 0.6 compatibility code 2011-10-28 10:59:10 +02:00
al.yazdi@gmail.com
cef7676b58 Fix for issue #125, create the table on the same connection as the ALTER and INSERT happen 2011-10-26 06:32:59 +00:00
Chris Withers
cda65c38b5 try to get firebird stuff working with 0.6.6 2011-02-10 17:02:42 +00:00
Chris Withers
b5a02cb7cf remove the alter_metadata feature 2011-02-10 16:49:20 +00:00
Chris Withers
c80120da55 work around firebird's insistence that indexes and constraints are dropped before columns that are references by them. 2011-02-10 15:19:00 +00:00
Chris Withers
500cb6f5df fix sqlite column dropper now that the table is only modified after the visitor is run 2011-02-10 15:17:28 +00:00
chrisw
adf4113a0b Fix issue 94 - it was impossible to add a column with a non-unique index.
Also implement more functionality with unique and foreign key constrains for sqlite.
2010-09-09 15:38:42 +01:00
chrisw
a085ffa590 implement column adding with foreign keys on sqlite 2010-09-09 13:58:41 +01:00
chrisw
5cf42fbf76 fix for issue 96: deleting a column in sqlite shouldn't delete all indexes
bonus: remove_from_table now removes indexes
2010-09-09 09:15:28 +01:00
iElectric
653e723ce1 move all exception classes to migrate.exceptions 2010-09-07 02:25:29 +02:00
iElectric
a3d3470d5e adding connection keyword to ORM methods 2010-07-11 17:22:28 +02:00
iElectric
8b0072b3e8 move to unittest2, update README for testing instructions 2010-06-20 15:29:16 +02:00
iElectric
6e025c4a4d add firebird to test_db.cfg.tmpl; fix bug when dropping a column in firebird: also drop related constraint or index 2010-05-11 22:52:07 +02:00
iElectric
ece9ffed35 fix MySQL failing tests with autoincrement 2010-05-02 20:31:50 +02:00
emil.kroymann
7912af18ed apply Emil Kroymann's patch for Issue 75 2010-01-07 20:10:47 +01:00
iElectric
7cb4b6363c applying patch for issue #61 by Michael Bayer 2009-07-13 18:45:52 +02:00
iElectric
de3c53989d add support for SA 0.6 by Michael Bayer 2009-06-29 10:18:03 +00:00
iElectric
75e93aa410 add not supported exceptions for sqlite constraints 2009-06-27 14:33:40 +00:00
iElectric
9f7ab96881 - completely refactored ColumnDelta to extract differences between columns/parameters (also fixes issue #23)
- fixed some bugs (passing server_default) on column.alter
- updated tests, specially ColumnDelta and column.alter
- introduced alter_metadata which can preserve altering existing objects if False (defaults to True)
- updated documentation
2009-06-27 14:13:27 +00:00
iElectric
a8c31eb25f adding basic support for firebird, fixes #55 2009-06-22 10:22:06 +00:00
iElectric
17cc5f36e6 finally, tests pass for all supported dialects 2009-06-21 12:51:33 +00:00
iElectric
672d9bd576 some more PEP8 love 2009-06-21 09:17:23 +00:00
iElectric
cde0f9b52d updated changeset tests. whole package is finally PEP8. fixed mysql tests&bugs. updated docs where apropriate. changeset test coverage almost at 100% 2009-06-20 22:33:03 +00:00
iElectric
7eafe744c2 - refactor migrate.changeset;
- visitors are refactored to be more unified
- constraint module is refactored, CheckConstraint is added
- documentation is partialy updated, dialect support table is added (unfinished)
- test_constraint was updated
NOTE: oracle and mysql were not tested, *may be broken*
2009-06-16 15:17:33 +00:00
iElectric
cc82a1ad12 update docs, delete obsolete code in constraints 2009-06-12 22:43:02 +00:00
iElectric
8a8b1d2366 use sqlalchemy preparer to do SQL quote formatting. this is a raw change, tests are yet to be written 2009-06-11 22:27:38 +00:00
jan.dittberner
5ecec7c680 mark ALTER TABLE ADD FOREIGN KEY as unsupported by SQLite
update corresponding test case
2009-02-18 20:08:37 +00:00
jan.dittberner
60409d80cd revert stupid test case breaking change 2009-01-25 13:40:55 +00:00
jan.dittberner
eb00570991 make migrate.changeset.databases PEP-8 clean and add it to the API docs 2009-01-25 12:52:33 +00:00
jan.dittberner
05819a6f70 apply patch for Issue #43 (better SQLite support) by Florian Apolloner 2008-12-30 20:43:40 +00:00
percious17
6c0694417f fixes to postgres, shell. removal of "run" module. 2008-12-02 18:27:16 +00:00
percious17
b267d64f9e now all databases are running at once. 2008-12-02 15:41:25 +00:00
percious17
f7e88199b4 all tests pass with postgres now 2008-12-02 15:25:12 +00:00
percious17
9f0bd657f4 most of the tests are now working with nose. 2008-12-02 05:11:36 +00:00
percious17
e4382ab75b missed a postgres identifier quoting on renaming 2008-11-27 00:17:55 +00:00
percious17
c7cbde7fea added hook functions which allow the dialects to specify how to indicate identifiers, as this is different in postgres.
Also, this fix includes a fix for modification of columns which have tables definied within a schema.  This was also broken in postgres.
2008-11-26 22:05:19 +00:00
christian.simms
f687cd3fe0 add support for SA 0.5 2008-08-28 01:17:44 +00:00
christian.simms
bf45f7da6d - make test_shell not assume Python code is compiled
- update results in test_shell so that it works in Postgresql
- make Oracle changesets generate valid sql syntax when a modified column's default value changes to NULL
2008-03-21 17:04:13 +00:00
jan.dittberner
32aeb8e95e integrated patch by Christian Simms posted at http://groups.google.com/group/migrate-users/browse_thread/thread/952a2185baf70c4d
fix all test cases for sqlalchemy>=0.4 and still works with sqlalchemy>=0.3.10
fixes #9
2008-02-14 19:10:47 +00:00
jan.dittberner
2cfe1fc31c moved trunk, branches and tags to project root
fixes Issue #5
2008-02-06 18:39:07 +00:00