diff --git a/modules/dvg/dvg_domain_prefix/dvg_domain_prefix.module b/modules/dvg/dvg_domain_prefix/dvg_domain_prefix.module index 1c5555d..2930b06 100644 --- a/modules/dvg/dvg_domain_prefix/dvg_domain_prefix.module +++ b/modules/dvg/dvg_domain_prefix/dvg_domain_prefix.module @@ -34,7 +34,13 @@ function dvg_domain_prefix_domain_bootstrap_full($domain) { // Copy structure. $table_with_prefix = $db_prefix . $table; - db_query("CREATE TABLE $new_table LIKE $table_with_prefix"); + $schema = drupal_get_schema($table_with_prefix); + if ($schema) { + db_create_table($new_table, $schema); + } + else { + db_query("CREATE TABLE $new_table LIKE $table_with_prefix"); + } } // If the table already has a prefix we're overriding it.