I need to merge two Drupal installations with a shared users table. Can Migrate module help me in this task? Can it import nodes to main Drupal installation from the second one respecting nodes' associations with their respective comments? Can Migrate attribute new nids for the nodes to be imported from the second website as otherwise nids of two Drupal installations will conflict with each other?
Or http://drupal.org/project/node_import module is better way to go in my case?
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | Screen shot 2010-11-11 at 5.31.33 PM.png | 59.62 KB | yngens |
Comments
Comment #1
yngens commentedMaybe I was supposed to post this within forums and not as an issue? If the module's maintainers think so, could you please transfer this to the forums?
Comment #2
mikeryanYes. Migrate tracks mappings from source IDs to destination IDs (i.e., it maps a nid from the external site to the nid of the resulting node in the main site) - when the comments are imported, the nids associated with them (pointing at nodes to the external site) are looked up in this table so they will be associated with the new nids on the main site.
Per above, when you migrate a node from an external site, the corresponding node created on the main site will have a new nid - there is no conflict with pre-existing content on the main site, but we do maintain the associations.
Comment #3
yngens commentedSounds great and very much suitable to my situation. mikeryan, could you please also confirm if I am thinking right about that only the following tables from second database need to be migrated on top of main database:
blog_node
blog_node_revisions
blog_node_type
blog_comments
blog_comment_upload_files
The content of usertable are shared and exactly the same as of the main site.
Generally, what are must migrate tables in any situation if we are talking about merging two different Drupal installations?
Thank you very much!
P.S. Here is a list of the tables from my second database, from which I need to merge nodes and comments to the main database.
It looks like this because I am trying to upgrade subdomain separately from main site from D5 to D6. Initially settings.php looked like this if it matters:
Comment #4
yngens commentedTrying to add a content set. On clicking Destination it gives some options like Comment, Node: Blog entry, Node: Image, Node: Page, Node: Story, User, Role, however I am going to migrate nodes of different types and would prefer them to maintain their respective node types. I do not want to attribute all of them to one type of nodes.
Maybe I misconfigured the setup, but can't figure out how to make such a content set, where it would be possible to select node as a Destination without specifying node type and so that nodes to be imported would be associated with their respective node types after import.
Comment #5
yngens commentedBecause, there is no UI for 6.x-2.x, I decided to go with 6.x-1.1. So the issue in #4 I am encountering with Migrate 6.x-1.1
Comment #6
mikeryanA content set (in Migrate 1 lingo) or migration (in Migrate 2 lingo) represents migration of content from a set of source data to a specific Drupal entity type (such as a node type). To migrate into multiple content types, you need to defined multiple content sets/migrations, one for each content type, with your source view/query filtered appropriately.
Comment #7
yngens commentedI wonder is it allowed to post a link to Paid Drupal Services forum, to where I had to take the subject of this issue, without changing its status. Please, interested follow this link: http://drupal.org/node/972600