Skip to Content.
Sympa Menu

freetds - Re: [freetds] Windows Question

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Patrick Corbett" <pcorbe81 AT maine.edu>
  • To: "FreeTDS Development Group" <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] Windows Question
  • Date: Mon, 16 Apr 2007 10:05:57 -0600

I think I'm using the wrong version of php_dblib.dll. Right now, I'm running
PHP 5.2.1 and using php_dblib.dll version "5.2.1.1" that I download from
Frank's site a couple weeks ago. I notice now that he has 5.2.2.2 up, and I
tried that and got a different error message, so I'm thinking that maybe I
need php_dblib.dll v. 5.2.1 ??? This might be the cause of everything...



On 4/16/07, Patrick Corbett <pcorbe81 AT maine.edu> wrote:

Do I need to specify a login and password in freetds.conf? I don't see
that listed as a setting here:
http://www.freetds.org/userguide/freetdsconf.htm

I know Frank mentioned that in the beginning but I see that "try domain
login" is depreciated and that I should just use the format DOMAIN/username
instead... but I don't see where a username is necessary at all according to
the page listed above...

Patrick

On 4/16/07, Patrick Corbett <pcorbe81 AT maine.edu> wrote:
>
> Why is freetds.conf necessary? Why can't it simply rely on PHP to make
> the connection to the DB as one already has to?
>
> I've tried several combinations and no luck so far... I am aware of the
> escaping and the need for double backslashes in PHP... I have my script
> working with php_mssql.dll. My file monitor (MS's File Monitor) shows that
> php_dblib.dll is being opened and soon after freetds.conf is being open.
> I made a folder writeable for the process that executes php_dblib.dll, but
> no log file is ever created... I even created the file and gave it all
> permissions, but still nothing (also tried dump file append).
>
> I haven't used PHP CLI much, is there a standard test someone could
> suggest that would help narrow down the possibilities?
>
> I'm sure there's something wrong on my end, just not sure what yet...
>
> Thanks,
>
> Patrick
>
> On 4/16/07, ZIGLIO, Frediano, VF-IT < Frediano.Ziglio AT vodafone.com>
> wrote:
> >
> > >
> > > Patrick Corbett wrote:
> > > > I reference it in my PHP connection string the following
> > > > way:
> > > >
> > > > $host = "server\instance";
> > > > mssql_connect($host, $user, $pass);
> > > >
> > > > So... the question is can I use named instances...?
> > >
> > > As stated previously, you can use the "instance" entry in
> > > freetds.conf.
> > > That's one way.
> > >
> > > I'm pretty sure you can use "instance\servername" with any FreeTDS
> > > library. I know Frediano added it for ODBC
> > > ( http://www.freetds.org/userguide/odbcconnattr.htm) but istr it
> > works
> > > everywhere. I don't have a server to test with, but you
> > > could try bsqldb.
> > > If it connects, PHP should be able to, too.
> > >
> >
> > No, this was implemented directly on ODBC. Current CVS have similar
> > option for libTDS (see parse_server_name_for_port in
> > src/tds/config.c).
> >
> > > Take care to escape the '\' character if need be. In your
> > > example above,
> > > you use double quotes. The PHP manual
> > > (http://www.php.net/manual/en/language.types.string.php ) says the
> > > backslash needs to be escaped in double-quoted strings:
> > >
> > > $host = "server\\instance";
> > > mssql_connect($host, $user, $pass);
> > > or
> > > $host = 'server\instance';
> > > mssql_connect($host, $user, $pass);
> > >
> > > Tell us how it works out. I might need to add something to the User
> > > Guide.
> > >
> >
> > I think so... however I cannot find specifications even for
> > server:port
> > syntax... this is a useful extension but not that documented.
> >
> > freddy77
> >
> > _______________________________________________
> > FreeTDS mailing list
> > FreeTDS AT lists.ibiblio.org
> > http://lists.ibiblio.org/mailman/listinfo/freetds
> >
>
>





Archive powered by MHonArc 2.6.24.

Top of Page