Jump to:

17452 Posts in 4473 Topics by 1971 members

Archive

SilverStripe Forums » Archive » Why does Silverstripe hardwire its storage engine to MyISAM?

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

Page: 1
Go to End
Author Topic: 2472 Views
  • julian
    Avatar
    Community Member
    17 Posts

    Why does Silverstripe hardwire its storage engine to MyISAM? Link to this post

    ... just curious as it seems like InnoDB is much better all round.

    Silverstripe 2.0.0, MySQLDatabase.php:

       /**
        * Create a new table with an integer primary key called ID.
        */
       public function createTable($tableName) {
          $this->query("CREATE TABLE `$tableName` (ID int(11) not null auto_increment, primary key (ID)) TYPE=MyISAM");
       }

    thanks,
    J

  • Sam
    Avatar
    Administrator
    679 Posts

    Re: Why does Silverstripe hardwire its storage engine to MyISAM? Link to this post

    We hardwired the storage engine so that database generation was done automatically.

    It would be fairly straight forward to add a static method, so that you could put this into your _config.php file:
    * MySQLDatabase::table_type("InnoDB")

    As to why we chose MyISAM, we basically went with it because we didn't need the extra features of InnoDB, and we though we'd go with the format with the most history. This may change in future releases as we might want to use transactions.

    2472 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.