ID:               34515
 Comment by:       mark at tranchant dot plus dot com
 Reported By:      jaba at inbox dot lv
 Status:           No Feedback
 Bug Type:         MySQLi related
 Operating System: Debian GNU/Linux
 PHP Version:      5.0.5
 New Comment:

In fact, any function that tries to do the assoc thing fails:
fetch_object fails, as does fetch_array with a resulttype of
MYSQLI_ASSOC or MYSQLI_BOTH. fetch_array works when called with
MYSQLI_NUM.

I'm just compiling the latest CVS snapshot, although the diff 'twixt
5.05's ext/mysqli directory and the CVS one doesn't give me much
hope...


Previous Comments:
------------------------------------------------------------------------

[2005-10-27 11:15:40] mark at tranchant dot plus dot com

I have the same problem. System is self-compiled PHP-5.05 and binary
distribution of MySQL-5.0.13, running on self-compiled Apache 2.0.55 on
x86 Linux.

mysqli_fetch_row() works as advertised, but mysqli_fetch_assoc() fails
silently, both called procedurally or in OO style.

------------------------------------------------------------------------

[2005-09-23 01:00:02] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".

------------------------------------------------------------------------

[2005-09-15 17:18:57] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5.0-win32-latest.zip



------------------------------------------------------------------------

[2005-09-15 17:12:54] jaba at inbox dot lv

Description:
------------
I am developing on Windows XP but the application production version is
supposed to be on Debian. Seems like debian MySQLi is not working
properly. I can use mysqli_fetch_row or $result->fetch_row, but
whenever I use $result->fetch_assoc() or mysqli_fetch_assoc($result) on
the same result, the application crashes and I receive no output at all.

Reproduce code:
---------------
<?php
$mysqli = new mysqli("localhost", "vaipusr", "parolite", "vaipdb");
if (mysqli_connect_errno()) {
   printf("Connect failed: %s\n", mysqli_connect_error());
   exit();
}
$query = "SELECT * FROM acc_users";
if ($result = $mysqli->query($query)) {
        while ($row = $result->fetch_assoc()) {
                echo '<pre>';
                print_r($row);
                echo '</pre>';
        }
   $result->close();
}
$mysqli->close();
?>

Expected result:
----------------
string representation of associated arrays of table rows 


Actual result:
--------------
nothing. application dies whenever you call mysqli_fetch_assoc


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=34515&edit=1

Reply via email to