Posted by asb on June 24, 2009 at 10:38pm
Jump to:
| Project: | Nodereferrer Create |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | critical |
| Assigned: | Unassigned |
| Status: | active |
Issue Summary
Hi,
when upgrading to D6, one of my sites had an nodereferrer_create field; this field seems to block access to the content type in question. I'm getting the error message:
This content type has inactive fields. Inactive fields are not included in lists of available fields until their modules are enabled.
Programme mit diesem Werk (field_programm_ref) is an inactive Node Referrers field that uses a nodereferrer_create_list widget.Whatever this means: NodeReferrer 6.x-1.0-beta1 is installed and active, and update.php has been run several times. What do I have to do to get access to this content type back?
Thanks & greetings, -asb
Comments
#1
btw: according to KarenS in All CCK custom fields are inactive after upgrading, this behaviour is not caused by CCK but by the contributed module ("If disabling and re-enabling the field module doesn't work you may have a field module that isn't implementing all the hooks").
Greetings, -asb
#2
My approach to resolve this issue (with crucial help from attheshow):
UPDATE `content_node_field_instance` SET `widget_type` = 'optionwidgets_select',`widget_module` = 'optionwidgets' WHERE `field_name` = 'field_[YOUR-FIELD-HERE]';
TRUNCATE `cache`;
After this, the field is still marked as "inactive" by CCK. So I once again disabled CCK and all related modules, ran update.php, enabled content.module, ran update.php again, enabled option widgets, ran update.php again and so forth. After enabling the rest of the CCK related modules, I got access to my CCK field back.
Hope this helps others, greetings,
-asb
#3
I just encountered a similar problem after another D5->D6 upgrade; the nasty approach from #2 seems to have worked this time again.
However, it would be nice to know how to fix this properly...
Greetings, -asb
#4
OK, I've been bitten by this issue on a third site, that's a total of 3 failures in 3 installations, where upgrading 'Nodereferrer create' during Drupal core/CCK upgrades doesn't work.
Changing the title to be more descriptive.
Structure of
content_node_field_instance:mysql> describe content_node_field_instance;+------------------+--------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+------------------+--------------+------+-----+---------+-------+
| field_name | varchar(32) | NO | PRI | | |
| type_name | varchar(32) | NO | PRI | | |
| weight | int(11) | NO | | 0 | |
| label | varchar(255) | NO | | | |
| widget_type | varchar(32) | NO | | | |
| widget_settings | mediumtext | NO | | NULL | |
| display_settings | mediumtext | NO | | NULL | |
| description | mediumtext | NO | | NULL | |
| widget_module | varchar(127) | NO | | | |
| widget_active | tinyint(4) | NO | | 0 | |
+------------------+--------------+------+-----+---------+-------+
10 rows in set (0.00 sec)
Applying the SQL from above (sample output):
mysql> UPDATE `content_node_field_instance` SET `widget_type` = 'optionwidgets_select', `widget_module` = 'optionwidgets' WHERE `field_name` = 'field_backlinks';Query OK, 8 rows affected (0.00 sec)
Rows matched: 8 Changed: 8 Warnings: 0
Result:
mysql> select widget_type,field_name,widget_active from content_node_field_instance where field_name ="field_backlinks";+----------------------+-----------------+---------------+
| widget_type | field_name | widget_active |
+----------------------+-----------------+---------------+
| optionwidgets_select | field_backlinks | 0 |
| optionwidgets_select | field_backlinks | 0 |
| optionwidgets_select | field_backlinks | 0 |
| optionwidgets_select | field_backlinks | 0 |
| optionwidgets_select | field_backlinks | 0 |
| optionwidgets_select | field_backlinks | 0 |
| optionwidgets_select | field_backlinks | 0 |
| optionwidgets_select | field_backlinks | 0 |
+----------------------+-----------------+---------------+
8 rows in set (0.00 sec)
After disabling content.module and everything depending on it, running update.php, then re-enabling content.module, then running update.php again, then re-enabling Option widgets and so forth, I'm finally getting:
mysql> select widget_type,field_name,widget_active from content_node_field_instance where field_name ="field_backlinks";+----------------------+-----------------+---------------+
| widget_type | field_name | widget_active |
+----------------------+-----------------+---------------+
| optionwidgets_select | field_backlinks | 1 |
| optionwidgets_select | field_backlinks | 1 |
| optionwidgets_select | field_backlinks | 1 |
| optionwidgets_select | field_backlinks | 1 |
| optionwidgets_select | field_backlinks | 1 |
| optionwidgets_select | field_backlinks | 1 |
| optionwidgets_select | field_backlinks | 1 |
| optionwidgets_select | field_backlinks | 1 |
+----------------------+-----------------+---------------+
8 rows in set (0.00 sec)
It would be nice, if the upgrade code for this module could be fixed.
#5
#6
subscribing