Understanding Data Types
In this chapter, we will learn what data types and their usage. We will go through the specific data types and understand what data can be stored in each of them. The data types include string, numeric, date and time, and other data types. String data types include char and varchar, binary and varbinary, blob, enum, set, and text. Numeric data types include bit, int, float, double, and decimal. Date and time data types include date, time, datetime, timestamp, and year.
We will learn from the perspective of MySQL data types, and will keep noting the differences between Oracle, PostgreSQL, and SQL Server wherever needed. We will also go through some examples of types and values of data to see how to assign them correctly ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access