|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #57289 Long ntext fields cause empty result fields
Submitted: 2006-10-10 15:05 UTC Modified: 2006-10-10 22:17 UTC
From: mike at pixor dot net Assigned: wez (profile)
Status: Closed Package: PDO_ODBC (PECL)
PHP Version: 5.1.6 OS: Windows XP SP2
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:
Solve the problem:
39 + 16 = ?
Subscribe to this entry?

 [2006-10-10 15:05 UTC] mike at pixor dot net
I'm working with a SQL Server 2005 Express database, trying to access data that has multiple ntext fields containing product descriptions in various languages.  I am able to access this data using odbc_connect() and odbc_exec(), but came across this bug when using PDO methods.  If I SELECT a field with type ntext, any fields I SELECT after this will be empty.  For example, using this SELECT statement where name is varchar(255) and description is ntext, I would have both name and description in my result:

SELECT name, description FROM test_tbl

however, this statement would return description but name would be empty:

SELECT description, name FROM test_tbl

I've attached a URL to some example code that will reproduce this bug, at least on my system using SQL Server 2005 Express.

Reproduce code:


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2006-10-10 22:17 UTC]
This bug has been fixed in CVS.

In case this was a documentation problem, the fix will show up at the
end of next Sunday (CET) on

In case this was a website problem, the change will show
up on the website in short time.
Thank you for the report, and for helping us make PECL better.

Fix will be in PHP 5.2, and should show up in the next stable snapshot.
Thanks for the self-contained test case.
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Mon Apr 19 04:01:23 2021 UTC