|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #58224 string length limit when reading data
Submitted: 2008-06-06 09:19 UTC Modified: 2008-10-16 05:22 UTC
From: danhen at web dot de Assigned:
Status: Closed Package: PDO_SQLITE (PECL)
PHP Version: 5_3 CVS-2008-06-06 (dev) OS: WinXP
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Bug Type:
From: danhen at web dot de
New email:
PHP Version: OS:


 [2008-06-06 09:19 UTC] danhen at web dot de
When using current PHP5.3 CVS version a string-limit around 980 bytes occours when reading text-data. The maximum length seems to differ when the table has another structure but is always around 980 bytes. When reading untill a = 981 everthing works fine.

Reproduce code:

$oDb = new PDO('sqlite:test.sqlite');

$oDb->query('CREATE TABLE test (a, b)');

$sStr = '';

for($i = 0; $i < 1000; $i++) {

  $sStr.= 'A';

  $oDb->query('INSERT INTO test (a, b) VALUES (\''.$i.'\', \''.$sStr.'\')');


class test {


$oStmt = $oDb->query('SELECT * FROM test WHERE a = \'982\'');

$oResult = $oStmt->fetchObject('test');



Expected result:
test Object ( [a] => 982 [b] => AAAAA ... a string containing 982 'A' )

Actual result:
Fatal error: Call to a member function fetchObject() on a non-object in sqlitetest.php on line 28


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2008-10-15 17:47 UTC]
Can you try a 5.3 snapshot from
 [2008-10-16 05:22 UTC] danhen at web dot de
Everything works fine with latest Thread-Save VC6-snapshot. Thanks.
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Wed Sep 22 23:03:39 2021 UTC