Re: MDB - Delete LOB
| From: | Manuel Lemos | Date: | Sun, 08 Jun 2003 20:53:45 +0000 |
| Subject: | Re: MDB - Delete LOB | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-17181@lists.php.net to get a copy of this message | ||
Hello,
On 06/08/2003 12:02 PM, Alexey Borzov wrote:
Binary strings are not suitable as large objects containers because you have to paste their whole contents in the query that creates or updated them. This means if it would not exceed your PHP memory limit, it would probably crash your Web server processes when you tried to insert large data. MySQL already has this problem. MS-SQL and other databases accessed via ODBC API are in worst situation because the data has to be encoded in hexadecimal (double the size) to be inserted via SQL. PostgreSQL has objects that you can use to store large amounts of data streaming it to the server. Although PostgreSQL objects are not perfect, I think they are better to store large objects than having to deal with the problems of pasting large data in SQL queries. -- Regards, Manuel Lemos Free ready to use OOP components written in PHP http://www.phpclasses.org/Hi all, I'm working on a project involving Large Object inside a DB. I started using postgresql and PEAR:MDB as db abstraction layer (by the way, very good package!), because PEAR:DB (that I used in the past) doesn't support LOB. The LOB handling works well, at least the insert in db and retrive from db. I'm looking for a simlpe way to delete lob from db...Maybe you can get rid of LOBs and just use the bytea fields? They are processed just like normal fields, without convoluted API, and only require some additional 'quoting' (dunno whether this quoting is directly supported by either DB or MDB). Read here: http://www.postgresql.org/docs/view.php?version=7.3&idoc=1&file=datatype-binary.html