Changing DB type from MySQL to MySQLi after installation

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • James Birkett
    Senior Member
    • Jun 2009
    • 331
    • 3.8.x

    Changing DB type from MySQL to MySQLi after installation

    If I was originally running mysql database type, then I change the config.php to mysqli instead of mysql (dbtype), but I did this after an install (i.e. when I had members & threads etc) - does this cause any difference? Does the dbtype have to be declared at installation then kept the same?

    I know vBulletin has database handlers which is why I presume changing the dbtype mid-way won't affect anything, i'm just looking for some clarification.
  • cellarius
    Senior Member
    • Aug 2005
    • 4586
    • 3.8.x

    #2
    It doesn't matter, you can change that as often as you want. I do that frequently when testing my modifications. MySQLi is not a different database format, it's in fact not even MySQL It's an improved database layer of PHP, and the database does not care what layer you use to access it. MySQLi is object oriented.

    See: http://de3.php.net/manual/en/book.mysqli.php

    Comment

    • James Birkett
      Senior Member
      • Jun 2009
      • 331
      • 3.8.x

      #3
      MySQLi offers improvements though so that's why I always use it over MySQL. As you say, more object-orientated.

      I was just making sure that the change wouldn't affect anything.

      EDIT: Seems to affect all of my modifications - I even rebuilt bitfields.
      Last edited by James Birkett; Sun 1 Nov '09, 1:50pm.

      Comment

      • cellarius
        Senior Member
        • Aug 2005
        • 4586
        • 3.8.x

        #4
        Yep, I first looked into this when I could not for the life of it track down a database related bug in one of my mods. Took me hours until I thought of testing it with mysqli.

        Comment

        • James Birkett
          Senior Member
          • Jun 2009
          • 331
          • 3.8.x

          #5
          I can't see why modifications would affect database handling. It all goes through vBulletin's database handling system so it shouldn't make any effect.

          Going to have to see what's causing my errors to appear now the error in all of my modifications is:

          Fatal error: Cannot use object of type mysqli_result as array in /home/user/public_html/forum/global.php(607) : eval()'d code(1330) : eval()'d code on line 4

          Comment

          • James Birkett
            Senior Member
            • Jun 2009
            • 331
            • 3.8.x

            #6
            Can anyone shed any light on this? Any way to get past this error without reinstalling my modifications?

            Comment

            widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
            Working...
            😀
            😂
            🥰
            😘
            🤢
            😎
            😞
            😡
            👍
            👎