Re: BYTEA vs BLOB

From: Eugene Yin <eugeneymail(at)ymail(dot)com>
To: John DeSoi <desoi(at)pgedit(dot)com>, Postgres List <pgsql-sql(at)postgresql(dot)org>
Subject: Re: BYTEA vs BLOB
Date: 2016-01-16 16:08:05
Message-ID: 563742622.6654475.1452960485450.JavaMail.yahoo@mail.yahoo.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-sql

When use Ora2Pg to migrate the Oracle to Pg, the BLOB data type in Oracle will supposedly be converted into BYTEA in Pg.  Is this achievable?  

If so, after the data become BYTEA, can I further convert the BYTEA into OID data type, and how to?

Thanks

Eugene

On Thursday, January 14, 2016 8:05 AM, John DeSoi <desoi(at)pgedit(dot)com> wrote:


> On Jan 12, 2016, at 7:45 PM, Eugene Yin <eugeneymail(at)ymail(dot)com> wrote:
>
> Now if I migrate the Oracle table to Postgres and change the data type to BYTEA, how will the photo file (BYTEA) be stored?
>
> 1) The whole photo data will be stored inside the table?
>
> Or
>
> 2) Only the reference to the data is stored inside the table, the data itself will be stored outside the table (but still within the database) for efficiency purpose?
>

This is a good summary of your options:

https://www.microolap.com/products/connectivity/postgresdac/help/tipsandtricks_byteavsoid.htm

John DeSoi, Ph.D.

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Andreas Joseph Krogh 2016-01-17 15:01:03 Re: BYTEA vs BLOB
Previous Message Michael Moore 2016-01-15 21:43:52 strip values from json doc