codigo5/diglin_mssql

Name: diglin_mssql

Owner: Codigo5

Description: :eyes: Mssql Adapter for Magento (read-only)

Forked from: diglin/diglin_mssql

Created: 2016-06-10 20:30:48.0

Updated: 2016-06-29 21:17:22.0

Pushed: 2016-08-08 15:06:57.0

Homepage:

Size: 14

Language: PHP

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

Diglin Mssql for Magento

Mssql Adapter for Magento. Be aware that it is not attended to replace MySQL for Magento Database. It is not fully implemented to support such a case.

Requirements
Installation
Via modman
Via composer

...
"require": {
    "diglin/diglin_mssql":"*"
},
"repositories": [
    {
        "type": "vcs",
        "url": "https://github.com/diglin/diglin_mssql.git"
    }
],
"extra":{
    "magento-root-dir": "./"
}

Manually
Configuration

Add into your app/etc/local.xml the following information and replace the placeholder with your own data

fig>
<global>
    <resources>
        <default_mssql>
            <connection>
                <host>{{db_host_mssql}}</host>
                <username>{{db_user_mssql}}</username>
                <password>{{db_pass_mssql}}</password>
                <dbname>{{db_name_mssql}}</dbname>
                <model>{{db_model_mssql}}</model>
                <initStatements>{{db_init_statements_mssql}}</initStatements>
                <type>{{db_type_mssql}}</type>
                <active>1</active>
            </connection>
        </default_mssql>
    </resources>
</global>
nfig>
Usage

In any location of your Magento Module:

ource = Mage::getSingleton('core/resource');

var $connection Diglin_Mssql_Model_Db_Adapter_Mssql */
nection = $resource->getConnection('default_mssql');

dump($connection->fetchAll('SELECT @@VERSION'));
r_dump($connection->fetchAll('exec sp_columns mytable'));

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.