HiveSQL for PHP developers

It is a bit tricky to enable PHP on Linux to work with MS-SQL servers. Here is a procedure for this to work:

  • install php-pdo-dblib (if you're using PDO)

  • then echo "" > /etc/php.d/mssql.ini

  • then restart your httpd

  • you also need the ODBC drivers curl > /etc/yum.repos.d/mssql-release.repo yum remove unixODBC-utf16 unixODBC-utf16-devel #to avoid conflicts sudo ACCEPT_EULA=Y yum install msodbcsql17 sudo pecl install sqlsrv sudo pecl install pdo_sqlsrv

  • You should add "" to php.ini You should add "" to php.ini

Thanks to @drakos for this information.

Last updated