I have a MySQL database from a Joomla MultiSite installation, where she has a set of tables with different prefixes for each Joomla site. When I export db via phpMyAdmin, it creates an SQL file in which tables are created and populated in alphabetical order. The problem is that tables for subordinate sites depend on tables for the main site, but in alphabetical order their prefixes are ahead of the main site. Thus, the export works fine, but when I try to import, I get an error message after the error and must manually move the sections in the SQL file to make sure that the dependent tables are created / populated first.
So, is it possible to export db via phpMyAdmin with tables in a specific order?
EDIT: Here's the error I get that should clarify things:
Error
SQL query: Documentation
CREATE ALGORITHM = UNDEFINED DEFINER = `bookings_bpjms`@`localhost` SQL SECURITY DEFINER VIEW `bookings_bpjms`.`j1_core_acl_aro` AS SELECT `bookings_bpjms`.`js0_core_acl_aro`.`id` AS `id` , `bookings_bpjms`.`js0_core_acl_aro`.`section_value` AS `section_value` , `bookings_bpjms`.`js0_core_acl_aro`.`value` AS `value` , `bookings_bpjms`.`js0_core_acl_aro`.`order_value` AS `order_value` , `bookings_bpjms`.`js0_core_acl_aro`.`name` AS `name` , `bookings_bpjms`.`js0_core_acl_aro`.`hidden` AS `hidden`
FROM `bookings_bpjms`.`js0_core_acl_aro` ;
MySQL said: Documentation
Parts of the js0_ import script come after parts of j1_, and therefore this error occurs. If I edit this file in a text editor (30+ megabytes and every day), I can find the js0_ parts and move them to the beginning, but this is tedious, requires a lot of time and errors.
source
share