pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedBlob Data type in postgres ?
3+ messages / 3 participants
[nested] [flat]
* Blob Data type in postgres ?
@ 2003-09-05 10:41 Somasekhar Bangalore <sbangalore@zensutra.com>
2003-09-05 10:58 ` Re: Blob Data type in postgres ? Andreas Schmitz <a.schmitz@cityweb.de>
2003-09-05 11:59 ` Re: Blob Data type in postgres ? Jouneau Luc <Luc.Jouneau@diamant.jouy.inra.fr>
0 siblings, 2 replies; 3+ messages in thread
From: Somasekhar Bangalore @ 2003-09-05 10:41 UTC (permalink / raw)
To: pgsql-admin
Hi ,
I would like to create a table with blob as a datatype.I found that postgres doesn't have a datatype called BLOB.
Is there any equivalent data type for this or a short cut ?
I appreciate if some one can help me in this regard.
Thank you all,
Regards,
Somasekhar Bangalore
Principal Software Engineer
ZenSutra Software Technologies Pvt. Ltd.
Suite 601, HM Geneva House
#14, Cunningham Road
Bangalore 560-052, India
Ph:+91-80-235-0481
Fax:+91-80-235-0486
Email: sbangalore@zensutra.com
Weaving the knowledge tapestry'
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Blob Data type in postgres ?
2003-09-05 10:41 Blob Data type in postgres ? Somasekhar Bangalore <sbangalore@zensutra.com>
@ 2003-09-05 10:58 ` Andreas Schmitz <a.schmitz@cityweb.de>
1 sibling, 0 replies; 3+ messages in thread
From: Andreas Schmitz @ 2003-09-05 10:58 UTC (permalink / raw)
To: Somasekhar Bangalore <sbangalore@zensutra.com>; pgsql-admin
have a look at bytea
regards
-andreas
On Friday 05 September 2003 12:41, Somasekhar Bangalore wrote:
> Hi ,
>
> I would like to create a table with blob as a datatype.I found that
> postgres doesn't have a datatype called BLOB. Is there any equivalent data
> type for this or a short cut ?
>
> I appreciate if some one can help me in this regard.
>
> Thank you all,
>
> Regards,
> Somasekhar Bangalore
> Principal Software Engineer
> ZenSutra Software Technologies Pvt. Ltd.
> Suite 601, HM Geneva House
> #14, Cunningham Road
> Bangalore 560-052, India
>
> Ph:+91-80-235-0481
> Fax:+91-80-235-0486
> Email: sbangalore@zensutra.com
>
> Weaving the knowledge tapestry'
--
Andreas Schmitz - Phone +49 201 8501 318
Cityweb-Technik-Service-Gesellschaft mbH
Friedrichstr. 12 - Fax +49 201 8501 104
45128 Essen - email a.schmitz@cityweb.de
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Blob Data type in postgres ?
2003-09-05 10:41 Blob Data type in postgres ? Somasekhar Bangalore <sbangalore@zensutra.com>
@ 2003-09-05 11:59 ` Jouneau Luc <Luc.Jouneau@diamant.jouy.inra.fr>
1 sibling, 0 replies; 3+ messages in thread
From: Jouneau Luc @ 2003-09-05 11:59 UTC (permalink / raw)
To: Somasekhar Bangalore <sbangalore@zensutra.com>; +Cc: pgsql-admin
As far as I am concerned, I think that lobs are managed in postgres with oid.
Create your table like this :
CREATE TABLE table_of_lobs (
title varchar(100),
content_reference oid);
content_reference is a handler on lobs data contained in specials postgres system tables called Toast.
Create a rule to automatically destroy LOB data when you delete a tuple in table_of_lobs :
CREATE RULE del_table_of_lobs AS ON DELETE TO table_of_lobs
DO SELECT lo_unlink(old.content) AS lo_unlink;
Once you've created your table, use lo_import/lo_export functions to import/export your LOB data in a pgsql session (you must be super useer)
or use LOBS management functions available in libpq in order to interface lobs data management in your favorite program language.
Regards,
Luc Jouneau
----- Original Message -----
From: Somasekhar Bangalore
To: pgsql-admin@postgresql.org
Sent: Friday, September 05, 2003 12:41 PM
Subject: [ADMIN] Blob Data type in postgres ?
Hi ,
I would like to create a table with blob as a datatype.I found that postgres doesn't have a datatype called BLOB.
Is there any equivalent data type for this or a short cut ?
I appreciate if some one can help me in this regard.
Thank you all,
Regards,
Somasekhar Bangalore
Principal Software Engineer
ZenSutra Software Technologies Pvt. Ltd.
Suite 601, HM Geneva House
#14, Cunningham Road
Bangalore 560-052, India
Ph:+91-80-235-0481
Fax:+91-80-235-0486
Email: sbangalore@zensutra.com
Weaving the knowledge tapestry'
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2003-09-05 11:59 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2003-09-05 10:41 Blob Data type in postgres ? Somasekhar Bangalore <sbangalore@zensutra.com>
2003-09-05 10:58 ` Andreas Schmitz <a.schmitz@cityweb.de>
2003-09-05 11:59 ` Jouneau Luc <Luc.Jouneau@diamant.jouy.inra.fr>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox