| ADOdb Library for PHP Manual | ||
|---|---|---|
| Prev | BlobDecode | Next |
Some databases require blob's to be decoded manually after doing a select statement. If the database does not require decoding, then this function will return the blob unchanged. Currently BlobDecode is only required for one database, PostgreSQL, and only if you are using blob oid's (if you are using bytea fields, we auto-decode for you). The default maxblobsize is set in $connection->maxblobsize, which is set to 256K in adodb 4.54.
In ADOdb 4.54 and later, the blob is the return value. In earlier versions, the blob data is sent to stdout.
$rs
= $db->Execute("select
bloboid from postgres_table where id=$key");
$blob =
$db->BlobDecode(
reset($rs->fields)
);
| Prev | Home | Next |
| BlobEncode | Up | PageExecute |