Re: Re: Re: MySQL has transactions

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Lincoln Yeoh <lyeoh(at)pop(dot)jaring(dot)my>
Cc: "Mitch Vincent" <mitch(at)venux(dot)net>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Re: Re: MySQL has transactions
Date: 2001-01-27 06:47:07
Message-ID: 20744.980578027@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers

Lincoln Yeoh <lyeoh(at)pop(dot)jaring(dot)my> writes:
> I'm wondering if TOAST is going to be efficient enough for me to plonk
> multimegabyte email attachments into the database.

Should work. The main limitation on TOAST is that it wants to treat
each datum as a unit, ie you must fetch or store the whole value in one
go. When your datums get big enough that that's inconvenient, you won't
like TOAST so much. I don't foresee it being a big issue for emailable
items though ...

> However I've also a suspicion that there might be problems doing

> INSERT INTO mytable (a) values ( 'aa.......');

> Where aa... is a few megabytes long :). There's probably a query size limit
> somewhere between my app and TOAST.

I've tested this, it works fine since 7.0 or so.

Amusing anecdote: since 7.0, MySQL's "crashme" test crashes when run
against Postgres. Postgres is fine, it's the perl job running the
crashme script that goes belly-up. It seems that crashme's loop that
tries to discover the maximum query length is more memory-hungry than
Postgres itself, and so the perl job hits the kernel-imposed maximum
process size before the backend does. Moral: before assuming Postgres
can't do something, make sure your own code can hold up its end...

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Adam Haberlach 2001-01-27 07:04:12 Re: Wild Cards
Previous Message Tom Lane 2001-01-27 06:30:59 Re: Trouble porting postgreSQL to WinNT

Browse pgsql-hackers by date

  From Date Subject
Next Message Oleg Bartunov 2001-01-27 07:18:53 Re: new version of contrib-intarray
Previous Message Tom Lane 2001-01-27 06:30:59 Re: Trouble porting postgreSQL to WinNT