Announcement

Collapse
No announcement yet.

SQL error going from 4.1.12 to 4.2

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

  • [Forum] SQL error going from 4.1.12 to 4.2

    Please help.

    Trying to upgrade from VBulletin 4.1.12 to 4.2 I get the following:

    Code:
    [LEFT][COLOR=#001F30][FONT=verdana]An error has occurred with your database. Please contact vBulletin Support for assistance.[/FONT][/COLOR][COLOR=#001F30][FONT=verdana]Module: 420a1, Step 1 Database Error:1074[/FONT][/COLOR][COLOR=#001F30][FONT=verdana]Column length too big for column 'url' (max = 255); use BLOB or TEXT instead[/FONT][/COLOR][COLOR=#001F30][FONT=verdana]Query:[/FONT][/COLOR][/LEFT]
    CREATE TABLE vbnavigation                (                    navid INT UNSIGNED NOT NULL AUTO_INCREMENT,                    name VARCHAR(20) NOT NULL DEFAULT '',                    navtype ENUM('tab','menu','link') NOT NULL DEFAULT 'tab',                    displayorder SMALLINT UNSIGNED NOT NULL DEFAULT '0',                    parent VARCHAR(20) NOT NULL DEFAULT '',                    url VARCHAR(500) NOT NULL DEFAULT '',                    state TINYINT UNSIGNED NOT NULL DEFAULT '0',                    scripts VARCHAR(30) NULL DEFAULT '',                    showperm VARCHAR(30) NULL DEFAULT '',                    productid VARCHAR(25) NOT NULL DEFAULT '',                    username VARCHAR(100) NOT NULL DEFAULT '',                    version VARCHAR(30) NOT NULL DEFAULT '',                    dateline INT NOT NULL DEFAULT '0',                    PRIMARY KEY (navid),                    UNIQUE KEY identity (name, productid),                    KEY productid (productid, state) [LEFT][COLOR=#001F30]    )[/COLOR][/LEFT]

  • #2
    Did you run yoursite/install/ ? It should upload the database for you.

    Comment


    • #3
      Originally posted by Grawl View Post
      Did you run yoursite/install/ ? It should upload the database for you.
      I uploaded everything in the upload folder and tried to upgrade as I've done a thousand times before by going to mysite/install/upgrade.php

      The upgrade stopped after 1% with that error.

      Comment


      • #4
        There is no more to the error?

        Comment


        • #5
          Originally posted by Zachery View Post
          There is no more to the error?
          No that's all it said. Then aborted install.

          Comment


          • #6
            Sorry, I'll look into a short term fix. But can you tell me which version of mysql you're running?

            Comment


            • #7
              You are running php 5.4
              I buy 420 forums

              Comment


              • #8
                Originally posted by Alfa1 View Post
                You are running php 5.4
                This db error has nothing to do with php 5.4. MySQL errors about key lenght are not from php.

                Comment


                • #9
                  Originally posted by Zachery View Post
                  Sorry, I'll look into a short term fix. But can you tell me which version of mysql you're running?
                  4.1.22

                  - - - Updated - - -

                  And I appreciate your help btw I have reverted back to 4.1.12 in the meantime... so don't sweat it if you can't find a solution right away. My forums are up and running regardless.

                  Comment


                  • #10
                    In your upload/install/includes/class_upgrade_420a1.php file find:

                    PHP Code:
                                        url VARCHAR(500NOT NULL DEFAULT ''
                    Replace with

                    PHP Code:
                                        url varchar(250NOT NULL DEFAULT ''
                    Last edited by Zachery; Tue 22 May '12, 6:30pm. Reason: updated the query

                    Comment


                    • #11
                      Note- After making the above change, when you re-start the install or upgrade process it is normal to get this "Startup Error"


                      Due to the following errors, the install/upgrade can not continue:
                      • Following is a list of files that are either missing or contain unexpected contents. The most likely cause is that all of the files from this release have not been properly uploaded. You should resolve this error before continuing.
                        /install/includes/class_upgrade_420a1.php - File does not contain expected contents


                      It is safe and OK to press "Ignore and Continue" and the installation should proceed as normal.

                      Comment


                      • #12
                        Thank you. I will try this out tonight and let you know how it went.

                        Comment


                        • #13
                          Note 2:

                          For UPGRADES you must do what Zachery says in post #10.

                          For NEW INSTALLS you must make the same change to a different file:

                          /installs/mysql-schema.php Open the file in a god text editor:

                          Find:
                          PHP Code:
                          url VARCHAR(500NOT NULL DEFAULT ''
                          and change it to
                          PHP Code:
                          url VARCHAR(250NOT NULL DEFAULT ''
                          Again this ONLY necessary for people running MySQL 4.1.x. All newer MySQ versions will work with the default code.

                          Comment


                          • #14
                            Done. Worked like a charm ! Thank you both very much

                            One last question... my hosting service is thinking of upgrading to mysql 5.x sometime in september. Should I think about doing something then to revert the table changes I made? Or does it not matter?

                            Thanks again!

                            Comment


                            • #15
                              It shouldn't matter too much.

                              Comment

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