0

Is it possible to integrate PHP 5.6 to SQL Server 2000 Or should I downgrade to PHP 4.x to do this?

I cannot update the server version nor can I convert the database to MySQL.

4
  • Have you tried ODBC or MS sqlsrv drivers? Commented Jun 9, 2015 at 0:37
  • I've read this thread and I guess I cannot connect with the sqlsrv 3.2. The ODBC driver gives me the error SQL Server does not exist or access denied but I've configured my server to allow remote connections and I've put the right IP address of the server. I'm still trying with the ODBC driver tho. Commented Jun 9, 2015 at 0:46
  • Why would you want to work with sql server 2000? use at least 2008 version instead. 2000 version is 6 feet under for quite some time now. Commented Jun 9, 2015 at 5:45
  • I'd like to work on a newer version of SQL Server, but the server in my office is not being upgraded. So I need to adapt to it. Commented Jun 16, 2015 at 1:27

1 Answer 1

1

I've managed to connect PHP 5.6 and SQL Server 2000. In Ubuntu, I used mssql functions and unixodbc drivers. In Windows, I used the SQL Server driver and odbc functions. And I could only use native PHP for it. (I tried with CI but it doesn't have the right config for it)

Here's the connection code for Windows:

$conn = odbc_connect("Driver={SQL Server};Server=".$server.";Database=".$database.";", $user, $password);
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.