Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> mapping datatypes

mapping datatypes

From: Doug Cowles <dcowles_at_nospambigfoot.com>
Date: Wed, 06 Oct 1999 22:03:36 -0400
Message-ID: <37FBFF78.18090AC7@nospambigfoot.com>


We're trying to put together a standards document and have a couple of outstanding questions about mapping java types to oracle types. We originally had enums and int (32bit) mapping to NUMBER. However, it seems as though Oracle as a smallint, and int datatype, or does it? I can create tables using those types. But my documentation doesn't say anything directly about those types. Sever manual ,

Table 10-2 Summary of Oracle Built-In Datatypes - does not contain these datatypes.
even float isn't mentioned -
They are mentioned farther down in Conversions (inserted below - see rest of question afterwards)

Table 10-3 ANSI Datatype Conversions to Oracle Datatypes

 ANSI SQL Datatype

Oracle Datatype

 CHARACTER (n), CHAR (n)                                 CHAR (n)
 NUMERIC (p,s), DECIMAL (p,s), DEC (p,s)        NUMBER (p,s)
 INTEGER, INT, SMALLINT                                 NUMBER (38)
 FLOAT (p)
FLOAT (p)
 REAL
FLOAT (63)
 DOUBLE PRECISION                                           FLOAT (126)
 CHARACTER VARYING(n), CHAR VARYING(n) VARCHAR2 (n)

So, does Oracle really have these datatypes? Or are they just to allow you to use the type when in actuality it is using a NUMBER(38) for an integer, smallint etc., If so, would it make sense to map java enum and java int to NUMBER(38)?

Why no mention of float in "Summary of Oracle Datatype Information" located in
Chapter 10 of Oracle8 Concepts (Built in Datatypes)?

Thanks,
Dc.


Received on Wed Oct 06 1999 - 21:03:36 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US