Every time I edit a user (even without changing their password), I get the error below:

user warning: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(hash, name) VALUES ('$P$BkKaA0PnSnjesZBdnFGJrgJBdB6/5A0', ) WHERE uid = 1' at line 1 query: UPDATE user_phpass SET (hash, name) VALUES ('$P$BkKaA0PnSnjesZBdnFGJrgJBdB6/5A0', ) WHERE uid = 1 in /home/greathe/base/includes/database.mysql.inc on line 172

any ideas?
thanks

Comments

douggreen’s picture

That code gets run when you submit the user edit form, regardless of whether you changed the password. So that part makes sense.

However, the SQL is messed up, and I don't see how the code could possibly generate it. Does line 32 of phpass.module say:

    db_query("UPDATE {user_phpass} SET hash = '%s' WHERE uid = %d", $phpass_hash, $uid);

That's the only "UPDATE user_phpass" in the code, so phpass is not messing this up. It's possible that some other module's db_rewrite_sql is causing the problem... Have you recently added some other module?

owen barton’s picture

Status: Active » Postponed (maintainer needs more info)
pwolanin’s picture

Status: Postponed (maintainer needs more info) » Closed (cannot reproduce)