Re: Large Objects
От | Karsten Hilbert |
---|---|
Тема | Re: Large Objects |
Дата | |
Msg-id | 20050102173824.C566@hermes.hilbert.loc обсуждение исходный текст |
Ответ на | Re: Large Objects (Martijn van Oosterhout <kleptog@svana.org>) |
Список | pgsql-general |
> > >BYTEA is not always pragmatic. What is the file is 100 megs? 256 megs? > > What is the size when bytea become inafective ? > I don't think it's so much a matter of effectiveness, it makes no > difference at all in storage space. Ah, thanks, good to know. Something new to learn every day... > The issue is that if you store it > in a field, accessing it becomes an all or nothing affair, which means > if it's a 100Mb object, it's all going to be accessed whenever you ask > for it. At least for reads you are wrong. You can use substring() on bytea quite nicely. Remember, however, that that operates on *bytes*, not characters. Also be careful about encodings being set for the connection. At least with PostgreSQL < 7.4 we found we had to "reset client_encoding" despite the docs saying encodings won't affect bytea field reads. Karsten -- GPG key ID E4071346 @ wwwkeys.pgp.net E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346
В списке pgsql-general по дате отправления: