Course Hive
Search

Welcome

Sign in or create your account

Continue with Google
or
Database Systems - Simple and Complex Data Types
Play lesson

Database Systems with SQL - Full Course - Database Systems - Simple and Complex Data Types

5.0 (0)
6 learners

What you'll learn

This course includes

  • 4.5 hours of video
  • Certificate of completion
  • Access on mobile and TV

Summary

Keywords

Full Transcript

There are 6 main categories of simple data types: Integer – whole numbers, positive or negative Decimal - floating point numbers, numbers with a decimal or fractional-value Character – Text characters that are fixed or varied lengths Time – date, time, or datetime, and may include time zone. Can also be a time interval Binary – 1s and 0s, just like the data stored in memory or on computer files Sematic – types that have a special meaning, such as BOOLEAN (1 is true and 0 is false), ENUM for enumerated values (like red yellow green for traffic lights), and MONEY for currency representation There are 4 main categories of complex data types: Collection – similar type of data organized in a collection such as a set or array Document – text data, typically JSON or XML Spatial - geometric information, such as lines, polygons, and map coordinates. Object – object-oriented programming constructs There are also system-defined types (built-in types). For example, MySQL has: FLOAT, CHAR, ENUM, SET, JSON, and POINT You can also create your own user-defined type using CREATE TYPE statement and specifying the name of the type and a base type which can be user or system defined. Example: CREATE TYPE Points AS INT. Creates a new type called Points with base type as an integer. Even though Points is an INT, you cannot compare it to something that is of type INT anymore since it’s now a different type. Note that MySQL does not support the CREATE TYPE statement, but Oracle, PostgreSQL, DB2, and SQL Server does. Subscribe to Appficial for more programming videos coming soon. Also, don't forget to click LIKE and comment on the video if it helped you out!

Course Hive

Continue this lesson in the app

Install CourseHive on Android or iOS to keep learning while you move.

FAQs

Course Hive
Download CourseHive
Keep learning anywhere