[PHP-DB] Apache, PHP4, access problem to MS SQL 7.0

2001-02-14 Thread FreakyMark

Can anybody help me about my serious problem to connect to MS SQL 7.0. I
tried to use the freetds-driver but i'm not able to connect with it. They
said that I must define the Serverconnection in the interfaces-file. I found
one in the freetds-directory but i don't know how to write it correct. I've
got a Linux-webserver and MS SQL runs on a WinNT4.0-Server.

Thanks for any help,
Martin




-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DB] Apache, PHP4, access problem to MS SQL 7.0

2001-02-14 Thread Darryl Friesen

 Can anybody help me about my serious problem to connect to MS SQL 7.0. I
 tried to use the freetds-driver but i'm not able to connect with it. They
 said that I must define the Serverconnection in the interfaces-file. I
found
 one in the freetds-directory but i don't know how to write it correct.
I've
 got a Linux-webserver and MS SQL runs on a WinNT4.0-Server.

There should be a file called 'interfaces' in whatever directory you
installed FreeTDS (our is in /usr/local/freetds).  That file lists all the
Sybase/MSSQL servers you can connect to.  Ours looks like this:

server1
query tcp tds4.2 128.233.x.y 1433
server2
query tcp tds7.0 128.233.x.y 1433

(substitute 128.233.x.y for the real IP numbers of your server).

For a 'standard' install of MSSQL server the port number is 1433.  Took me a
while to find that.  If you're using FreeTDS, the third parameter of the
interfaces file can be the version of TDS protocol to use when talking to
that server.

Also, make sure you have the SYBASE environment variable set to the
directory where FreeTDS is installed.

I'd recommend trying sqsh (SQL command line shell for Sybase servers --
works with MSSQL as well) to test the connection.  It assumes a full Sybase
install, so the Makefile took a little tweaking in order to get it to
compile, but once installed it will help you debug the connection problem,
test your queries etc.
Not sure of a download site, but if you search Google you're bound to find
it.

Hope that helps.


- Darryl

 --
  Darryl Friesen, B.Sc., Programmer/Analyst[EMAIL PROTECTED]
  Education  Research Technology Services, http://gollum.usask.ca/
  Department of Computing Services,
  University of Saskatchewan
 --
  "Go not to the Elves for counsel, for they will say both no and yes"



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]