php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #29993 mssql_connect returns NULL
Submitted: 2004-09-06 07:48 UTC Modified: 2004-09-07 00:21 UTC
From: mel dot boyce at gmail dot com Assigned:
Status: Not a bug Package: MSSQL related
PHP Version: 5.0.1 OS: Windows XP
Private report: No CVE-ID: None
 [2004-09-06 07:48 UTC] mel dot boyce at gmail dot com
Description:
------------
mssql_connect() returns NULL regardless of a sane and completed connection.

PHP-5.0.1 zip file from http://www.php.net/

php.ini is identical to php.ini-recommended with the mssql extension enabled.

Reproduce code:
---------------
$foo = mssql_connect("server", "user", "pass");
var_dump($foo);

Expected result:
----------------
$foo != NULL

Actual result:
--------------
$foo == NULL

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-09-07 00:21 UTC] fmk@php.net
mssql_connect() and mssql_pconnect() can return false or a valid resource link. This is infact what it does. If the connect fails for any reason ot wil return false, not null.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 18:01:29 2024 UTC