4

Has anyone managed to get Magento running under MSSQL? Since 1.6 there is the possiblity to change the PDO driver, using some steps:

  1. Rename Mysql.php files to Mssql.php

    app/code/core/mage/Core/Model/Resource/Type/Db/Pdo/Mysql.php

    lib/Varien/Db/Adapter/Pdo/Mysql.php

    lib/Varien/Db/Statement/Pdo/Mysql.php

  2. Modify the files to actually use Mssql

  3. Modify app/etc/local.xml and app/etc/config.xml to use mssql adapter

This basically works, but then you are running into the problem that all (or at least most) install scripts are using MySQL specific syntax. Has anyone undergone the hassle of porting them all to MSSQL?

Any other thoughts in this regard besides waiting for Magento 2.0 to support this natively?! ;)

5
  • you need to change all the mysql resource model. The Problem is, all the classes use MySQL syntax (!= SQL syntax). MySQL is not always SQL standard complaint. Feb 21, 2013 at 14:15
  • @FabianBlechschmidt I would hope that there are only a few you will have to rewrite, since resource models generally use the abstracted notation like $this->_getWriteAdapter()->select()->from($this->getTable('catalog/category'))->where('path = ?', (string)$rootId); etc, so these should still work under MSSQL
    – mpaepper
    Feb 21, 2013 at 14:24
  • As I said, you have to reimplement the MYSQL resource models. All other should be abstracted :) Feb 21, 2013 at 14:43
  • Did you find an answer? Share it! :-) Mar 14, 2013 at 15:28
  • @FabianBlechschmidt No, I did not find anything, yet. It seems this is too much work and we will have to wait for Magento 2
    – mpaepper
    Mar 19, 2013 at 11:00

1 Answer 1

1

There was a presentation from Maksym Iaroshenko at Developers Paradise – Friends, Fun, Snow: Magento non-MySQL implementations

I also found this video (same guy) presenting at Meet Magento Poland: "Magento non-MySQL implementations" Maksym Iaroshenko, Dmytro Vasylenko, Eltrino

During one of the Magento Hackathons this repo was created: MongoDB-OrderTransactions

I don't see a working version of Magento 2 on anything else than MySQL in the next 12 months (at least).

The challange with another RDBMS and Magento is that just porting the database tables with the same schema won't be a solution, because some refactoring is needed, some stuff should be moved at a database level (depends on RDBMS, would be nice to see stored views used).

Another challange is providing a set of tools for the actual migration and management of the environment so developers that would want to contribute not to break their heads for couple of weeks just to get some kind of functional dev environment.

Start a repo on github and see how other people feel about this.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.