Re: Mapping Oracle types to PostgreSQL types

Andreas Pflug <pgadmin@pse-consulting.de>

From: Andreas Pflug <pgadmin@pse-consulting.de>
To: Shridhar Daithankar <shridhar_daithankar@persistent.co.in>
Cc: jm@poure.com, pgsql-hackers@postgresql.org
Date: 2003-10-17T13:49:44Z
Lists: pgsql-hackers
Shridhar Daithankar wrote:

> Jean-Michel POURE wrote:
>
>> Dear friends,
>>
>> I would like to port Compiere CRM from Oracle to PostgreSQL (and 
>> release it for free).
>>
>> At first I would like to convert the data schema. This is not 
>> difficult as Compiere is written using portable types like NUMBER 
>> (i,d) which can be replaced by NUMERIC (i,d), etc... A series of 
>> Search/Replace is sufficiant. There are other solutions in Contrib to 
>> connect to Oracle and export the data (Bruce). Don't blame me to 
>> search in another (silly) direction...
>
>
> Rather than declaring numeric, create them as integer/float of 
> appropriate size and add appropriate constraints. Numeric can be 
> slower for large data load w.r.t native integers.


float is *not* an alternative to numeric. While integer or int8 should 
be usable for NUMBER(i), the non-rounding precision of numeric is vital 
for such an application.

Regards,
Andreas