Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>I didi everything google teaches and can't connect with TCP/IP successfully. Then I do these steps to make it work in my home computer:</p> <p>step 1. Enable TCP/IP in SQL Server Network Configuration for your DB instance.<br> step 2. Choose properties of TCP/IP and click IP Addresses tab.<br> step 3. Inactive all IP address except 127.0.0.1.<br> step 4. Set TCP Port to 1433 in 127.0.0.1 and IPALL.<br> step 5. Restart sql server service.<br> step 6. Connect it with TCP/IP using '127.0.0.1\SQLEXPRESS,1433' in Toad for SQL Server freeware, it works!<br> step 7. Connect it with same server string in php, it works!<br> step 8. If you need read Chinese string into php program as I am, download MS SQL Server driver for PHP(<strong>Believe me, don't even try php_mssql stuff, it'll drive you crazy with Chinese data</strong>). For PHP 5.2x, use ts_VC6 version. For 5.3X, use ts_VC9 version (especially when in Win7).<br> step 9. Edit php.ini (For Appserv, it's under C:\Windows7; for WAMPserver 2.2, it's under c:\wamp\bin\php\php5.3.8), find extension=... line groups. Add 'extension = specific sql erver driver dll filename you are to use.<br> step 10. Unzip the file downloaded in step 8 and copy the specific dll (or copy all) to php extension directory (you can find it in php.ini's extension_dir=... line). For Appserv, you better copy it to c:\windows\system32, too(Don't ask me why?).<br> step 11. restart apache service of Appserv or restart Wampserver.<br></p> <p>Now you can use TCP/IP to connect with SQL Server 2008 and you can read utf-8 string (in my case) into php program correctly.</p> <p>Hope this helps those who are deperately looking for this solution, as i am.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload