Closed (fixed)
Project:
Drupal core
Version:
10.0.x-dev
Component:
user.module
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
20 Feb 2011 at 03:34 UTC
Updated:
9 May 2022 at 23:17 UTC
Jump to comment: Most recent
Comments
Comment #1
bryancasler commentedLines 3501, 3502 and 3503 are the contents of this foreach loop.
Comment #2
bryancasler commentedTo resolve this I created an user account. Then in the DB I changed that accounts UID to 29. I then went back to the website and deleted the account. Not perfect, but the error seems to have gone away. Someone in the Drupal IRC chatroom suggested that this was a similar error as http://drupal.org/node/826640#comment-3790638
Comment #3
droplet commentedit pass $nodes object which contains diff UID than your other site user table
Comment #4
bfroehle commentedIt sounds like it is fixed. The node table records the user id of the authors. When you overwrote the users table, you had nodes which no longer corresponded to valid authors.
It is possible that other tables which involve user id's are also slightly corrupted, in particular the users_roles table. Directly editing the SQL tables without knowing what you are doing is, in general, a bad idea.
Comment #5
bryancasler commentedRedid my table migration, but before I did I deleted all the roles and users on the site I was migrating the user table to. This resulted in me having no problems.
Comment #7
anithakr19 commentedThank you so much for sharing this. It was really helpful for me to solve the issue when I encountered it! Thanks a bunch!
Comment #8
mile23See: #2653342: Warnings in user_node_load() for deleted users
Comment #9
darrellduane commentedI temporarily added this code into the user.module file so that I could see which nodes were causing the problem and quickly edit them to have a new user assigned to them that has data in the user table. It seems that when I deleted some users the nodes that were owned by them didn't get updated.