Closed (fixed)
Project:
DBTNG Migrator
Version:
7.x-1.0
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
17 Aug 2011 at 00:52 UTC
Updated:
25 Nov 2012 at 22:30 UTC
Hi, I'm getting errors converting a mysql table to an SQLite. It all seems to be related to i18n
SQLSTATE[HY000]: General error: 1 table block has no column named i18n_mode
SQLSTATE[HY000]: General error: 1 table locales_target has no column named i18n_status
SQLSTATE[HY000]: General error: 1 table menu_custom has no column named i18n_mode
SQLSTATE[HY000]: General error: 1 table menu_links has no column named language
SQLSTATE[HY000]: General error: 1 table taxonomy_term_data has no column named language
SQLSTATE[HY000]: General error: 1 table taxonomy_vocabulary has no column named language
Comments
Comment #1
josh waihi commentedThis looks very similar to #1230430: relation "locales_source" does not exist. From about comment #10.
Please be sure all update hooks have run before you try dbtng_migrator.
Please make this as a duplicate if #1230430: relation "locales_source" does not exist solves your issue.
Comment #2
rwt commentedNo updates are available and cache was cleared.
#1230430 talks about changing the hook_schema_alter (because i18n adds new columns). How would I do that ?
Comment #3
josh waihi commentedLIne 27 of dbtng_migrator.batch.inc:
This is the code to create each table in the new database. Which carries out the same task as drupal_install_schema which means the additional columns that i18n adds should also be present.
If you do some debugging around this piece of code, like inspecting the schema after its been generated, it may give indication as to why your issue is occurring.
Comment #4
felubraAnyone solved this?
Comment #5
bartl commentedI saw the same bug: using drush, migration worked, but using the web admin interface, columns went missing, and the tables remained empty. And I think I got it fixed.
The problem is that the required
hook_schema_alterfunctions were not being executed. And most likely the cause is that these hooks are inmodule.installfiles. So the functions simply did not exist, and the statementcould not invoke them.
So what I need to do is load all
module.installfiles.So in file
dbtng_migrator.batch.inc, functiondbtng_migrator_batch_initialise_destination, right under line 11, which isI added the line:
This is a function defined in
includes/install.inc.I tried to run the migration again via the web interface, and this time it all worked well, for all tables.
Comment #6
josh waihi commentedThanks bartl, I've commited a slightly different patch that loads the install files in the same function the schema alter is called so that this should work when using the batch API in the web interface.