Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 2.5.0b5

Bug #9092 LOB and streams
Submitted: 2006-10-19 07:17 UTC
From: frehling at 3il dot fr Assigned: lsmith
Status: Closed Package: MDB2 (version 2.2.2)
PHP Version: 5.0.4 OS: Windows XP
Roadmaps: (Not assigned)    
Subscription  


 [2006-10-19 07:17 UTC] frehling at 3il dot fr (Jean-Christophe Frehling)
Description: ------------ The stream_get_contents function reports a warning : Warning: stream_get_contents() [function.stream-get-contents]: MDB2_LOB::stream_stat is not implemented! in c:\Inetpub\wwwroot\tpoccasion2007\test.php on line 16 I implemented an empty method in LOB.php that works fine, it also works fine with @stream_get_contents($row[0]); Test script: --------------- <?php require_once 'MDB2.php'; $login = "tp"; $password = "test"; define ("dsn", "mysql://{$login}:{$password}@srv-linux/jcf_tp_occasion"); $db = MDB2::connect(dsn); if (MDB2::isError($db)) die($db->getMessage()); $db->setOption('portability', MDB2_PORTABILITY_ALL); $db->setOption('debug', 2); $requete = "SELECT O_Image FROM occasion WHERE O_id=9"; $res = $db->query($requete,'blob'); $row = $res->fetchRow(); $str = stream_get_contents($row[0]); var_dump($str); //header("content-type: image/jpeg"); //echo base64_decode($str); ?> Expected result: ---------------- No warning Actual result: -------------- resource(12) of type (stream) Warning: stream_get_contents() [function.stream-get-contents]: MDB2_LOB::stream_stat is not implemented! in c:\Inetpub\wwwroot\tpoccasion2007\test.php on line 16 string(29584)

Comments

 [2006-10-25 11:44 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2006-10-25 11:48 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2006-10-25 11:52 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!