Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What datatype in oracle would map to a Java int?

What type in Oracle (10 Express Edition) would be the "same" as a Java int?

like image 693
benstpierre Avatar asked Jun 14 '10 20:06

benstpierre


People also ask

What is Smallint in Java?

Short in java is equivalent to small int as there range is same.It has a minimum value of -32,768 and a maximum value of 32,767 (inclusive).

What is the default precision and scale for a number in Oracle?

The NUMERIC and DECIMAL data types can specify only fixed-point numbers. For those data types, the scale ( s ) defaults to 0. The FLOAT data type is a floating-point number with a binary precision b. The default precision for this data type is 126 binary, or 38 decimal.


1 Answers

Java's int has a range of -2,147,483,648 to 2,147,483,647 - so Number(10,0) is as close as you're going to get...

like image 70
Martin Milan Avatar answered Oct 05 '22 03:10

Martin Milan