php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #35473 $ sign in the MS SQL 2000 database name
Submitted: 2005-11-29 12:54 UTC Modified: 2005-11-29 13:02 UTC
From: parthk at bsil dot com Assigned:
Status: Not a bug Package: *Database Functions
PHP Version: 4.4.2RC1 OS: Windows 2000
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: parthk at bsil dot com
New email:
PHP Version: OS:

 

 [2005-11-29 12:54 UTC] parthk at bsil dot com
Description:
------------
Hi,


I am trying to coonect to MS SQL 2000 from PHP. The connection is all the times but when i give a database name with $ sign in it then it fails.

Can you let me know if we have way out from this

Thanks
Parth

Reproduce code:
---------------
$myServer = "localhost";
$myUser = "sa";
$myPass = "";
$myDB = "DE$CIP";

$s = @mssql_connect($myServer, $myUser, $myPass)
or die("Couldn't connect to SQL Server on $myServer");

$d = @mssql_select_db([DE$CIP], $s)
or die("Couldn't open database $myDB");


Expected result:
----------------
Get connected to the database

Actual result:
--------------
Notice: Undefined variable: CIP in D:\inetpub\livesite\DE_2\catalog\sql.php on line 6
Couldn't open database DE

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-11-29 13:02 UTC] sniper@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.


 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Wed Jul 08 02:01:27 2020 UTC