Changes between Version 4 and Version 5 of Migrate06to07
- Timestamp:
- 09/30/09 20:58:54 (4 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Migrate06to07
v4 v5 1 == ManyToMany relationship column names == 1 == self-referential ManyToMany relationship column names == 2 3 The algorithm to generate column names for self-referential ManyToMany relationship was changed slightly to fix ticket #69. 2 4 3 5 If you are upgrading an existing application (written using an earlier version of Elixir) and you are using self-referential ManyToMany relationships, you will get error messages like this after upgrading: … … 47 49 48 50 Rename the columns in the database:: 49 How this step is done depends on the database you are using. Note that some databases (notably SQLite) do not support renaming columns at all, so you might need to workaround the problem by for example, renaming the table, create a new table with the correct column names and copy data from the old table to the new table. See the test_upgrade test for an example (source:/elixir/trunk/tests/test_m2m.py#L141).51 How this step is done depends on the database you are using. Note that some databases (notably SQLite) do not support renaming columns at all, so you might need to workaround the problem by for example, renaming the table, create a new table with the correct column names and copy data from the old table to the new table. See the test_upgrade_rename_col test for an example (source:/elixir/trunk/tests/test_m2m.py#L141). 50 52 51 53 Revert to the old format used to produce the column names:: 52 use... 54 You can revert to use the old format by using the following code '''before''' you declare any of your classes: 55 {{{ 56 #!python 57 from elixir import options 58 options.M2MCOL_NAMEFORMAT = options.OLD_M2MCOL_NAMEFORMAT 59 60 [your classes here] 61 62 setup_all() 63 }}} 53 64 54 65 Use local_colname:: … … 62 73 == bidirectional self-referential ManyToMany relationship table names == 63 74 64 The algorithm changed slightly to fix ticket #19.75 The algorithm to generate table names for bidirectional and self-referential ManyToMany relationship was changed slightly to fix ticket #19. 65 76 66 77 If you are upgrading an existing application (written using an earlier version of Elixir) and you are using self-referencial ManyToMany relationship, you are likely to get an exception like this after upgrading: … … 83 94 84 95 == local_side and remote_side arguments on ManyToMany relationships renamed to local_colname and remote_colname == 96 97 You simply need to update your code to match the new names. 98 99 == Deprecated act_as_list extension == 100 101 You should use SQLAlchemy's orderinglist extension instead. See wiki:Recipes/UsingEntityForOrderedList for an example using Elixir.
