php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #28192 mssql_select_db() 30 chars
Submitted: 2004-04-27 22:30 UTC Modified: 2004-04-28 00:11 UTC
From: docv00d00 at hotmail dot com Assigned:
Status: Not a bug Package: MSSQL related
PHP Version: 4.3.6 OS: windows 2003
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
28 + 33 = ?
Subscribe to this entry?

 
 [2004-04-27 22:30 UTC] docv00d00 at hotmail dot com
Description:
------------
mssql_select_db() doesnt let you select a database thats longer than 30 characters?

Reproduce code:
---------------
$Server = "server\\server,1433";
$User = "sa";
$Pass = "password";
$DB = "Thirty_Characters_or_more_db_name_here";

$s = mssql_connect("$Server", "$User", "$Pass");

$d = mssql_select_db("$DB", $s)or die("Couldn't open database $DB");

Expected result:
----------------
unable to select 'Thirty_Characters_or_more_db_na' from sysbase table...

Actual result:
--------------
same as above

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-04-28 00:11 UTC] fmk@php.net
This is a limitation in the library (from Microsoft) that is used for the php extension. Microsoft has not updated the library since SQL Server 6.x where column, table and database names was limited to 30 chars.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu May 16 17:01:37 2024 UTC