I am looking for a method of importing and exporting node data into a Drupal 6.x site. This could take the form of a custom module, a methodology using existing modules, or as further development of an existing module.
I have a reasonably large Drupal site that has many thousands of nodes. There are many relationships with about 15 or so Content Types. The relationships are defined using mostly nodereference fields, backlinks in views and to some extent nodereferrer. I am using Ubercart. I am on Drupal 6.16. Any other information that anyone needs will be gladly provided.
I imported these nodes for the most part into Drupal using Node Import. It took me a long bumpy time but I finally figured out how to get the multi-value fields to work (the text field widget must be a Select List).
Here is what I (and I have to think many other people) need to do.
1. After my initial import there will be some editing within the typical Drupal edit form.
2. I then want to export the entire data set of Content Type’s nodes (or else some subset using Views). I would expect to export the NID or perhaps the SKU of Ubercart Products for use as a key field when reimporting these back into Drupal.
3. I would then edit these nodes and copy and past them with some changes to create new nodes. I would do this using Excel, with sorting, search and find, cut and paste, etc., ultimately saving it back to a csv file format.
4. In fact one way to make this process sweet is to fully edit one node as a kind of template, export it and then add rows using the exact format of that csv file.
5. I do not want to do this in XML.
6. I need to be able to import and export multi-value fields like nodereference fields and taxonomy terms.
Here is my experience so far:
1. I tried Feeds. Feeds does a good job with importing and updating nodes. However, it does not map multi-value fields and that does not seem to be on the developer's agenda.
2. I have looked at Table Wizard, Migrate and Data but Feeds seems to be the most useful of the bunch. The combination of Table Wizard with Migrate might work.
3. Node Import - does import multi-value fields - reliably (use || between values and use the Select Widget for the text field).
4. If I import nodes using the Node Import Module then I can't get Feeds to update the nodes that are imported using Node Import because it is looking for GUID as the key field - which is created by Feeds - and it is not there unless Feeds was used to import the nodes in the first place.
5. The Node Import Update module seems like it might work. However, the documentation such as it is is in a long and winding thread (http://drupal.org/node/422282) and, not being a coding developer I find this confusing and really a non-starter for me. You have to hack the code to tell it which field to use as the key field and what node type you are working with. Even that is not obvious and I can't get it not to overwrite previous nodes.
6. I am able to reliably export to a csv file using the Views Bonus Pack with a Feed page. The multi-value fields don't have the delimiters but I can add them in using a search and replace for the most part. Not perfect because of this problem but still the only solution I have found that is close.
7. I have tried VBO and Editview. VBO is useful for bulk editing a few fields perhaps but is way too dependent on computer memory and is unstable when you are looking at lots of nodes. Nowhere near what Excel would do for editing ease. Editview is even worse. You have to save each node as you edit it and that can take a long time.
8. By the way I had to disable Feeds because it interferes with Node Import.
So to sum up here is what I need:
1. I can import my nodes now so I don’t need that functionality.
2. I need to export all the CCK fields, node fields like title, NID, body, all the Product fields from Ubercart – all into a csv file that I can then edit.
3. Ideally I would use Views to do this so I could easily control which records and fields to export. (The best way to work with the data is in chunks at a time.)
4. Then I need to reimport these into Drupal. During this import the system needs to search for any unique values in one key field, which would be either the NID or the SKU.
5. If a value already exists the system will update only the fields that have changed and will not overwrite information that has not changed. Actually it could overwrite the fields without damage if in my csv that information was exactly the same anyway.
6. However, if a field were not defined in my csv file then no that field’s value in Drupal would not be changed.
7. If there were fields without an NID then the system would create a new node.
8. If I were using the SKU (or some other CCK field) as a key field then it would create an error forcing me to put in a unique Key field datum.
9. It must handle multi-value fields, in particular node reference fields and taxonomy terms. The export format needs to have delimiters in the fields. It is OK if the information in the multi-value fields is NIDs or Node Titles. I’m not sure what the equivalent is for Taxonomy terms is but I am open to suggestion on that.
10. It must handle image fields, preferably as a URL. The intention is to upload a bunch of images into a folder and be able to specify the URL in my csv file so I don’t have to do a lot of image loading.
11. Again this can be a module, a well-documented method using existing modules (wouldn’t that be nice), or further development of an existing module.
Comments
multi cvs import ubercart drupal
you are trying to do what I'm trying to do..
but at the end you have tried any options did you find a suitable solution or did you customize something was pre existing?
thanks milplus
subscribe...
subscribe...
subscribe...
subscribe...
Subscribe
Subscribe
csv mulrifield import
subscribe to what?
Utiliza FEEDS TAMPER
Utiliza FEEDs junto con este módulo para dentro de un campo, crear valores múltiples separándolos con el carácter que queramos.
Modulo:
http://drupal.org/project/feeds_tamper
Configuración del campo SKU:
http://drupal.org/files/issues/rfay_dell_gazelle_Selection_021.png
http://drupal.org/files/issues/rfay_dell_gazelle_Selection_020.png