This thing is particularly annoying, two times a bit of experience, a record.
Keywords: freetds, PDO, MSSQL, Linux, CentOS7
Download Freetds:wget ftp://ftp.freetds.org/pub/freetds/stable/freetds-0.91.100.tar.gz
Unzip, toggle, then set:./configure--with-tdsver=8.0--prefix=/usr/local/freetds--enable-msdblib--with-gnu-ld--enable-shared --enable-static
Compile and install: Make && make install
Change the default setting for FreeTDS: vim/usr/local/freetds/etc/freetds.conf (the semicolon in front of the TDS version under [Global]; Remove
Download Pdo_dblib:wget Https://pecl.php.net/get/PDO_DBLIB
Unzip, toggle, then set:./configure--with-php-config=/usr/local/php/bin/php-config--with-pdo-dblib=/usr/local/freetds
Compile and install: Make && make install
Join Pdo_dblib.so to PHP.ini
Get!
Operations | CentOS 7 for PHP installation MSSQL-PDO expansion