Announcement

Collapse
No announcement yet.

Database error after upgrade to 3.8.7

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Database error after upgrade to 3.8.7

    I've recently upgraded my forum from 3.8.4 to 3.8.7 and am now getting the following error:

    Unknown column 'gm.groupid' in 'where clause'

    In an old thread, I found the following suggestion:
    Code:
    alter table `groupmessage` add `groupid` int(10) unsigned NOT NULL;
    Run

    Will this resolve my issue in 3.8.7, and if so, where do I run the command?

    Thanks.

  • #2
    I'd say probably. What is the query that is throwing the error?
    Translations provided by Google.

    Wayne Luke
    The Rabid Badger - a vBulletin Cloud demonstration site.
    vBulletin 5 API

    Comment


    • #3
      This is the query:

      Invalid SQL:


      SELECT SQL_CALC_FOUND_ROWS
      gm.*, user.*, gm.ipaddress AS messageipaddress

      ,avatar.avatarpath, NOT ISNULL(customavatar.userid) AS hascustomavatar, customavatar.dateline AS avatardateline,customavatar.width AS avwidth,customavatar.height AS avheight, customavatar.width_thumb AS avwidth_thumb, customavatar.height_thumb AS avheight_thumb, filedata_thumb, NOT ISNULL(customavatar.userid) AS hascustom

      FROM groupmessage AS gm
      LEFT JOIN user AS user ON (gm.postuserid = user.userid)
      LEFT JOIN avatar AS avatar ON(avatar.avatarid = user.avatarid) LEFT JOIN customavatar AS customavatar ON(customavatar.userid = user.userid)


      WHERE gm.groupid = 1
      AND (gm.state IN ('visible'))

      ORDER BY gm.dateline DESC
      LIMIT 0, 10;

      Comment


      • #4
        Yes, the query above should resolve the error. I'd make it an auto increment field though.
        Translations provided by Google.

        Wayne Luke
        The Rabid Badger - a vBulletin Cloud demonstration site.
        vBulletin 5 API

        Comment


        • #5
          Originally posted by Wayne Luke View Post
          Yes, the query above should resolve the error. I'd make it an auto increment field though.
          Thanks, can you please tell me where/how to run it?

          Comment


          • #6
            You can run queries within the vBulletin Admin Control Panel by going to Maintenance -> Execute SQL Queries.

            To run Queries in the Admin Control Panel you need to edit your config.php file and add your user ID to the Can Run Queries section. It looks like:

            // ****** USERS WITH QUERY RUNNING PERMISSIONS ******
            // The users specified here will be allowed to run queries from the control panel.
            // See the above entries for more information on the format.
            // Please note that the ability to run queries is quite powerful. You may wish
            // to remove all user IDs from this list for security reasons.
            $config['SpecialUsers']['canrunqueries'] = '';

            Place your user id between the single quotes.
            Translations provided by Google.

            Wayne Luke
            The Rabid Badger - a vBulletin Cloud demonstration site.
            vBulletin 5 API

            Comment


            • #7
              Thanks very much, Wayne. I'll run that this morning.

              Comment


              • #8
                Thanks Wayne, that fixed it.

                Comment

                widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                Working...
                X