I want to import a list, a single column of city names, having the client populate the other required fields (e-mail, contact person, etc.) later. But when I run a node import job, I get a "this field is required" because it is required by some of the CCK field types I am importing into.

Is there any way to override this, maybe a check box, "ignore required fields" on the page "Map file columns (step 4 of 8)" could do the trick?

Until there is, I will set the default value of the required fields to "node_import_delete" and empty them after import, with this from phpmyadmin:

UPDATE content_type_customer_unit SET field_contact_person_value = replace(field_contact_person_value, 'node_import_delete', '');
UPDATE content_type_customer_unit SET field_email_value = replace(field_email_value, 'node_import_delete', '');
field_email_value

Comments

ressa’s picture

Note: For the fields to be truly empty, ignore the above SQL, and set the content to NULL, like this:

UPDATE content_type_customer_unit SET field_contact_person_value = NULL WHERE field_contact_person_value = 'node_import_delete';
UPDATE content_type_customer_unit SET field_email_value = NULL WHERE field_email_value = 'node_import_delete';
Encarte’s picture

subscribe

EvanDonovan’s picture

Seems to me that you shouldn't empty out required fields, but rather configure the content type to accept a default value like "" or "n/a". Don't know if that would solve the issue...

Encarte’s picture

Version: 6.x-1.0-rc4 » 6.x-1.1
Category: feature » bug

If you try to import to a node type that has a required field NodeImport wont let you, even if the importing user doesn't have permissions to edit that field. Filling that field would result in an permission override and so I think this can be considered a bug. I think it's important that Node Import honours CCK permissions.

ressa’s picture

Issue summary: View changes
Status: Active » Closed (outdated)