sql server connection ???!!!

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
minos_mks
Forum Commoner
Posts: 69
Joined: Thu Feb 04, 2010 1:58 am

sql server connection ???!!!

Post by minos_mks »

how can i connect my php code to sql server DB in my network ???!!!
User avatar
Christopher
Site Administrator
Posts: 13596
Joined: Wed Aug 25, 2004 7:54 pm
Location: New York, NY, US

Re: sql server connection ???!!!

Post by Christopher »

Have you read this page carefully, and all the comment at the bottom?

http://www.php.net/manual/en/function.mssql-connect.php

If you have, then show us the code you tried (do not post real usernames or passwords).
(#10850)
User avatar
requinix
Spammer :|
Posts: 6617
Joined: Wed Oct 15, 2008 2:35 am
Location: WA, USA

Re: sql server connection ???!!!

Post by requinix »

Know that depending on your setup (PHP version, SQL Server version, platform, stuff like that) you may need to use the SQLSRV extension, available for download from Microsoft. It's basically the same style of coding as you'd do using mssql but with different functions.
minos_mks
Forum Commoner
Posts: 69
Joined: Thu Feb 04, 2010 1:58 am

Re: sql server connection ???!!!

Post by minos_mks »

thank you all , but i am kind of confused cause my Db admin give me the server name , and told me that the user name and pass is the same as my network pass and she doesn't know any thing about php and all what she is talking about is the odbc. and allot of comment in that link of (mssql-connect) so i need to know the steps ???!!! please help if you can.....
User avatar
mecha_godzilla
Forum Contributor
Posts: 375
Joined: Wed Apr 14, 2010 4:45 pm
Location: UK

Re: sql server connection ???!!!

Post by mecha_godzilla »

Hi,

For the benefit of anyone else interested in this question, the following page has some useful examples and advice for anyone wanting to use ODBC with PHP:

http://www.ibm.com/developerworks/opens ... index.html

HTH,

Mecha Godzilla
minos_mks
Forum Commoner
Posts: 69
Joined: Thu Feb 04, 2010 1:58 am

Re: sql server connection ???!!!

Post by minos_mks »

thanks mecha it looks like this link is very useful for me. i will read it and tray it Thanks again
Post Reply