I'm using the following code:
try {
$con = new PDO("sqlsrv:Server=172.20.21.193,9090;Database=sgt","deb","123123");
$con->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
} catch (PDOException $e) {
die ("Erro na conexao com o banco de dados: ".$e->getMessage());
}
but is giving error while trying to connect. The PDO driver is installed. What other library or driver should I install, for my application to access the database? The PHP version is 5.6.9 (Linux Debian 8.1) and SQLServer is 2008 (access will be remote).