We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 13825
    • 55 Posts
    Just trying out the new version (0.9.6.1) and I’m getting a fairly frequent error when login in after registration for a web users.
    I’m using the standard websignup and weblogin snippets.

    Execution of a query to the database failed - Incorrect integer value: ’NULL’ for column ’id’ at row 1

    SQL: REPLACE INTO `dev_bluesky`.`modx_active_users` (internalKey, username, lasthit, action, id, ip) values(-11, ’jamesd’, ’1194789125’, ’998’, ’NULL’, ’127.0.0.1’)

    Any ideas how this can be fixed? Seems to be related to being logged in to the manager at the same time.
    Thanks.

    (on a related note - I used to have an issue where having requested a new password and clicked on the link sent to the email, there was an error which read something like there was an error retrieving your account contact the administrator...am I right in thinking this has been fixed? seems like it has smiley

    • Damn. Thought we had gotten all of the STRICT sql_mode related errors. You can disable MySQL 5.x’s new strict SQL modes, or you can edit line 108 of assets/snippets/weblogin/weblogin.inc.php to remove the single quotes around the $itemid variable which is being inserted into the REPLACE statement, i.e.
              $sql = "REPLACE INTO $dbase.`".$table_prefix."active_users` (internalKey, username, lasthit, action, id, ip) values(-".$_SESSION['webInternalKey'].", '".$_SESSION['webShortname']."', '".$lasthittime."', '".$a."', ".$itemid.", '$ip')";
      


      Thanks for the report.