RES: Adaptive Server connection failed (Php + freetds)

"Frederick William Borges Pohl" <[email protected]>
Newsgroups gmane.comp.db.tds.freetds
Message-ID <[email protected]>
James

My ./;tsql -C command gave me the following result:

Compile-time settings (established with the "configure" script)
                            Version: freetds v0.82
             freetds.conf directory: /usr/local/freetds/etc
     MS db-lib source compatibility: no
        Sybase binary compatibility: no
                      Thread safety: yes
                      iconv library: yes
                        TDS version: 5.0
                              iODBC: no
                           unixodbc: no


Looking at my freetds.conf, I have the following entry

[MyServer2k]
;       host = ntmachine.domain.com
        host = 10.10.192.6
        port = 1433
        tds version = 8.0

If I run TDSVER=7.0 ./tsql -H <ip_addr> -p 1433 -U <username> I don´t get any error message, just a "1>" prompt:

locale is "en_US.UTF-8"
locale charset is "UTF-8"
Password:
1>

If I change the tds version parameter to 7.0 on the freetds.conf and run tsql, I get the same error as before:
 
./tsql -S <ip_name> -U <user_name>

Msg 20009, Level 9, State -1, Server OpenClient, Line -1
Unable to connect: Adaptive Server is unavailable or does not exist
There was a problem connecting to the server

Since I´m  not using the -H parameter, tsql should read the freetds.conf file which I already specified the tds version to 7.0

Do I have to refresh, rebuild or restart something to validate the changes made to the freetds.conf ?

One other question is regarding freetds version. I have the same system running with 0.64 version and I was thinking of installing this older version instead of 0.82.
Is there a repository where I can download older versions?

Thank You,

Fred Pohl
 

-----Mensagem original-----
De: [email protected] [mailto:[email protected]] Em nome de James K. Lowden
Enviada em: quinta-feira, 19 de junho de 2008 23:05
Para: FreeTDS Development Group
Assunto: Re: [freetds] Adaptive Server connection failed (Php + freetds)

Frederick William Borges Pohl wrote:
> 
> ./tsql -H <ip_address> -p 1433 -U <username>
> 
> The result was:
> 
> locale is "en_US.UTF-8"
> locale charset is "UTF-8"
...
> Msg 20009, Level 9, State -1, Server OpenClient, Line -1
> 
> Unable to connect: Adaptive Server is unavailable or does not exist

You're probably not using the right TDS version.  When you use "tsql -H",
you're bypassing freetds.conf.  The TDS version used depends on the
built-in options (which you can check with "tsql -C").  

Since you're using --with-mssql, I suppose you're connecting to a
Microsoft server, so you want:

	$ TDSVER=7.0 ./tsql -H ip_addr -p 1433 -U user

or, better, 

	$ ./tsql -S servername -U username

TDSDUMP and TDSDUMPCONFIG should tell you anything else you need to know. 


HTH.

--jkl
_______________________________________________
FreeTDS mailing list
[email protected]
http://lists.ibiblio.org/mailman/listinfo/freetds


Esta mensagem, incluindo seus anexos, pode conter informações privilegiadas e/ou de caráter confidencial, não podendo ser retransmitida sem autorização do remetente. Se você não é o destinatário ou pessoa autorizada a recebê-la, informamos que o seu uso, divulgação, cópia ou arquivamento são proibidos. Portanto, se você recebeu esta mensagem por engano, por favor, nos informe respondendo imediatamente a este e-mail e em seguida apague-a.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.