By Georgique on
Is there any way to merge two or more nodes? Also it is quite important to merge nodes with such fields as reference fields.
Is there any way to merge two or more nodes? Also it is quite important to merge nodes with such fields as reference fields.
Comments
are you meaning
are you meaning node_reference module ?
Drupal, AWS, DevOps
No. I have two different
No. I have two different nodes and want to merge it to one node. I don't know how yet but looking for any ready solutions
Merging nodes
Does anyone have an idea about this? How to merge nodes ?
For exemple: we have 2 nodes, we keep the title of the first, appends the body of the second to the first, adds the images from the image_field of the second to the image_field of the first ?
Thx.
Encountered same problem
My problem:
I have just written a custom action to create nodes to match a given textfield in an existing node type, then reference that node instead (I know I could probably have used feeds, but it got a bit fiddly). My code checks for duplicates wen making the new parent node, and references existing node if so.
Because the field was a simple text field I now have a lot of nodes that I know are duplicates, just because users made spelling errors or different naming conventions. I will have to merge these nodes manually as an administrative user.
Possible solutions:
One simple but longwinded way I could tackle this is to use a custom view with views bulk operations (vbo). If I make views with exposed filters for things like title and node_ref fields, then I can filter by title for items that I think might be duplicates of each other.
I then decide which item I would like to keep (merge target), filter for items that node_reference the duplicate versions, select them in the vbo view and use the 'modify node fields' action to change all their node references to match the chosen merge target. I can now delete the duplicate nodes as they are not referenced by anything else.
I think what I might try to do instead of the above method is write an action that will compare selected items in a vbo view, populate empty fields from those duplicates that have been filled, then use a db_query to alter any node references to point at the merge target and delete the others. The reason I would choose to do this from vbo rather than automate duplicate checking completely is that in my case duplicates may not be very clear, eg different titles etc.
User reference merge has been tackled
This problem has begun to be tackled by Reference User Merge.
They welcome expansion.
Did you finally find a solution to merge nodes?
To the drupal community, is there a way to merge two or three similar nodes of the same content type into one? I need a solution to this as soon a possible. Am doing maintenance on a D6 website with duplicate nodes.