Re: TEXT and BLOBS - Mailing list pgsql-general

From Peter Pilsl
Subject Re: TEXT and BLOBS
Date
Msg-id 20001109020057.A1551@i3.atat.at
Whole thread Raw
In response to TEXT and BLOBS  ("Martin A. Marques" <martin@math.unl.edu.ar>)
Responses Re: TEXT and BLOBS  ("Martin A. Marques" <martin@math.unl.edu.ar>)
List pgsql-general
On Wed, Nov 08, 2000 at 10:36:58AM -0300, Martin A. Marques wrote:
> I want to find out how confused I am. ;-)
> I'm testing something on a Postgres 7.0.2 database. I made a small table with
> two columns, one serial and the other TEXT, and tried to make serveral
> inserts with PHP.
> Some went OK, until I tried to insert a large amount of text. It failed. Of
> course, I did it on porpose to check the 8 K tuple limitation.
> Until here, am I right?
> So, now I'm gonna try to make inserts to a table just like the other one, but
> with the slight change of making the text column a oid column.
> The questions are:
> 1) where are the blobs stored?
> 2) Is it posible to insert a chunk of text that has not been saved to a file?
> 3) where is all the documentation on the behave of BLOBS? All I have found
> was in Bruce's book. I couldn't find such things in the users documentations.
>

I cant speak for PHP, but in perl or in C you have a documented module
that will handle this things.  (in perl its DBD::Pg). You dont need to
save the text to a file first, you can write directely into the blob.

The principal things are explained in the postgres-programmers-guide
you can find at
http://www.at.postgresql.org/devel-corner/docs/programmer/
in chapter 16 'Large Objects'

Although, dealing with blobs seems to be a dangerous things, cause I
didnt find a proper backup-method until now :-(

peter



--
mag. peter pilsl

phone: +43 676 3574035
fax  : +43 676 3546512
email: pilsl@goldfisch.at
sms  : pilsl@max.mail.at

pgp-key available

pgsql-general by date:

Previous
From: Matt Beauregard
Date:
Subject: Re: Relation 'pg_user' does not exist
Next
From: Tom Lane
Date:
Subject: Re: Relation 'pg_user' does not exist