PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » Database » DB_DataObject » Bug #4182

mysql blob support

Details

Request #4182mysql blob support
Submitted2005-04-19 16:59 UTC
Fromtherion_5 at hotmail dot com
Assignedalan_k
StatusClosed
PackageDB_DataObject
PHP Version4.3.10
OSany
Roadmaps(Not assigned)

Comments

[2005-04-19 16:59 UTC] therion_5 at hotmail dot com

Description:
------------
blob data can be escaped by one of following calls:
- mysql_escape_string
- mysql_real_escape_string

[2005-04-20 07:13 UTC] therion_5 at hotmail dot com

Here is patch. Sorry can't give you diff, coz i'm still on old version (waiting for multiple db patch)

Cast.php
// ...
function toStringFromString(...) {
// ...
switch($db)
{
// ...
case 'mysql':
return "'".mysql_escape_string($this->value)."'";
// ...
}

// ...
}

function toStringFromBlob(...){
// ...
switch($db)
{
// ...
case 'mysql':
return "'".mysql_escape_string($this->value)."'";
// ...
}

// ...
}
// ...