Oracle data types

Source: Internet
Author: User

The core of the Oracle database is the table, with the following common data types used by the columns in the table:
CHAR (length)
Stores a fixed-length string. The length of the parameter is specified, and is padded with spaces if the stored string is less than length.
The default length is 1 and the maximum is 2000 bytes.
VARCHAR2 (length)
Stores variable-length strings. length specifies the maximum size of the string. The default length is 1 and is no longer than 4000 characters.
Number (P,s)
You can store either floating-point numbers or integers, and p represents the maximum number of digits (in the case of decimals including integral and fractional parts).
And the decimal point, P is 38 by default, and S refers to the number of decimal places.
DATE
Stores the date and time, storage era, 4-bit year, month, day, hour, minute, and second.
TIMESTAMP
Not only the date of the month day, the time division seconds, and the second after 6 bits, and also contains the timezone.
Clob
Storing large text, such as storing unstructured XML documents
Blob
Store binary objects, shapes, videos, sounds, and more.

Example:

The actual storage of the digital format input
Number 1234.567 1234.567
Number (6,2) 123.4567 123.46
Number (4,2) 12345.67 has entered more than the specified precision, the database cannot be stored

Oracle data types

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.