Chapter 4 - Slides Flashcards
What are the naming conventions of a table and column name?
- Must begin with a letter
- Upto 30 characters long
- Alphanumeric, and can use $/_/#
- Spaces and Hyphens cannot be used
- Must be unique
- Cannot be an Oracle server-reserved word.
- Case insensitive.
- Should be short and meaningful
True or False? Data types help to optimize storage space.
True
The ____ type is a character data type to store variablelength alphanumeric data in a column.
VARCHAR2
What is the maximum allowable size for a VARCHAR2 type?
4000 Characters
_____ is the most appropriate type for a column whose
values do not have a fixed length
VARCHAR2
True or False? If a VARCHAR2 value is longer than the specified size is entered, the longer values are truncated.
False, an error is generated
True or False? The CHAR data type uses the storage more efficiently and processes data faster than the VARCHAR2 type.
True
The maximum allowable size for a CHAR type character is:
2000 characters
True or False? If a Char value longer than the specified size is entered, however, an
error is generated. The longer values are not truncated.
True
When a number type is used for a column, its
precision and scale can be specified optionally, using
the general syntax:
fieldname NUMBER [([precision,][scale])]
The precision value includes:.
only the digits, and does
not include formatting characters, such as the
currency symbol, commas, or the decimal point
_____ is the total number of significant digits in the number, both to the left and to the right of the decimal
point. It n can range from 1 to 38.
Precision
a _____ requires 1 to 22 bytes.
NUMBER
What are the three Number data subtypes:
Integer
Fixed-Point
Floating Point
The scale value for number can range from __ to __.
-84 to 127
A FLOAT value is represented internally as NUMBER. The precision p can range from _ to _ binary digits.
1 to 126
A FLOAT value requires
from _ to __ bytes
1 to 22
The DATE data type is used for storing date and time
values. The range of allowable dates is between
January 1, 4712 B.C. and December 31, 9999 A.D.
True or False? There is no need to specify size for the DATE type.
True
The default date format is
DD-MON-YY HH:MM:SS A.M.