SQL Data Types:-
- Each column in database table must have column name and datatypes.
- SQL Datatypes on column defines what type of data column can hold.
- Example : Integer, date, character, time , etc.
Type of SQL datatype:-
- Numeric data types
- Character data types
- Date and Time
- Binary data types
- Boolean data types
- Array data types
- XML data types
1.Numeric data types :-
These are used to store the numeric values.
They are INT, DECIMAL, Float datatype.
2.Character data types :-
They are used to store character string.
They are CHAR, VARCHAR and TEXT
3.Date and Time :-
These are used to store date and time values.
They are DATE, TIME and Timestamp datatypes.
4. Binary data Types:
These are used to store binary data such as Image, audio files.
They are BLOB and BYTEA
5- Boolean data Types :-
This data type is used to store logical values .
Datatype is Boolean and values are TRUE and FALSE.
6- Array data Types :-
These are used to store array of values
Example array and json
7- XML data types:-
This data type is used to store XML data.