{"id":846,"date":"2026-10-13T02:40:04","date_gmt":"2026-10-13T02:40:04","guid":{"rendered":"https:\/\/sites.rutgers.edu\/joann-ordille\/?page_id=846"},"modified":"2026-10-13T02:40:04","modified_gmt":"2026-10-13T02:40:04","slug":"data-types","status":"publish","type":"page","link":"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/","title":{"rendered":"Data Types"},"content":{"rendered":"<p><strong>Table 2.5.2: Common MySQL data types: INTEGER<\/strong><\/p>\n<table style=\"border-collapse: collapse;width: 68.5061%\" border=\"2\">\n<thead>\n<tr>\n<th style=\"width: 25.4083%\" width=\"114\"><strong>Data type<\/strong><\/th>\n<th style=\"width: 21.9601%\" width=\"99\"><strong>Storage<\/strong><\/th>\n<th style=\"width: 52.6316%\" width=\"237\"><strong>Notes<\/strong><\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<th style=\"width: 25.4083%\" width=\"114\"><strong>TINYINT<\/strong><\/th>\n<th style=\"width: 21.9601%\" width=\"99\">1 byte<\/th>\n<th style=\"width: 52.6316%\" width=\"237\">Signed range: -128 to 127<br \/>\nUnsigned range: 0 to 255<\/th>\n<\/tr>\n<tr>\n<th style=\"width: 25.4083%\" width=\"114\"><strong>SMALLINT<\/strong><\/th>\n<td style=\"width: 21.9601%\" width=\"99\">2 bytes<\/td>\n<td style=\"width: 52.6316%\" width=\"237\">Signed range: -32,768 to 32,767<br \/>\nUnsigned range: 0 to 65,535<\/td>\n<\/tr>\n<tr>\n<th style=\"width: 25.4083%\" width=\"114\"><strong>MEDIUMINT<\/strong><\/th>\n<td style=\"width: 21.9601%\" width=\"99\">3 bytes<\/td>\n<td style=\"width: 52.6316%\" width=\"237\">Signed range: -8,388,608 to 8,388,607<br \/>\nUnsigned range: 0 to 16,777,215<\/td>\n<\/tr>\n<tr>\n<th style=\"width: 25.4083%\" width=\"114\"><strong>INTEGER or INT<\/strong><\/th>\n<td style=\"width: 21.9601%\" width=\"99\">4 bytes<\/td>\n<td style=\"width: 52.6316%\" width=\"237\">Signed range: -2,147,483,648 to 2,147,483,647<br \/>\nUnsigned range: 0 to 4,294,967,295<\/td>\n<\/tr>\n<tr>\n<th style=\"width: 25.4083%\" width=\"114\"><strong>BIGINT<\/strong><\/th>\n<td style=\"width: 21.9601%\" width=\"99\">8 bytes<\/td>\n<td style=\"width: 52.6316%\" width=\"237\">Signed range: -2<sup>63<\/sup> to 2<sup>63<\/sup> -1<br \/>\nUnsigned range: 0 to 2<sup>64<\/sup> -1<\/p>\n<p>2<sup>63 <\/sup>is 9,223,372,036,854,775,808.<\/p>\n<p>2<sup>64 <\/sup>is 18,446,744,073,709,551,616.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>&nbsp;<\/p>\n<p><strong>Table 2.5.2: Common MySQL data types: DECIMAL<\/strong><\/p>\n<table style=\"border-collapse: collapse;width: 68.611%\" border=\"2\">\n<thead>\n<tr>\n<th style=\"width: 25.6887%\" width=\"114\"><strong>Data type<\/strong><\/th>\n<th style=\"width: 21.866%\" width=\"99\"><strong>Storage<\/strong><\/th>\n<th style=\"width: 52.4478%\" width=\"237\"><strong>Notes<\/strong><\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<th style=\"width: 25.6887%\" width=\"114\"><strong>DECIMAL(M,D)<\/strong><\/th>\n<th style=\"width: 21.866%\" width=\"99\">Varies depending on <em>M<\/em> and <em>D<\/em><\/th>\n<th style=\"width: 52.4478%\" width=\"237\">Exact decimal number where <em>M<\/em> = number of significant digits, <em>D<\/em> = number of digits after decimal point<\/th>\n<\/tr>\n<tr>\n<th style=\"width: 25.6887%\" width=\"114\"><strong>FLOAT<\/strong><\/th>\n<td style=\"width: 21.866%\" width=\"99\">4 bytes<\/td>\n<td style=\"width: 52.4478%\" width=\"237\">Approximate decimal numbers with range: -3.4E+38 to 3.4E+38<\/td>\n<\/tr>\n<tr>\n<th style=\"width: 25.6887%\" width=\"114\"><strong>DOUBLE<\/strong><\/th>\n<td style=\"width: 21.866%\" width=\"99\">8 bytes<\/td>\n<td style=\"width: 52.4478%\" width=\"237\">Approximate decimal numbers with range: -1.8E+308 to 1.8E+308<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>&nbsp;<\/p>\n<p><strong>Table 2.5.2: Common MySQL data types: DATE and TIME<\/strong><\/p>\n<table style=\"border-collapse: collapse;width: 68.7159%\" border=\"2\">\n<thead>\n<tr>\n<th style=\"width: 25.3333%\" width=\"114\"><strong>Data type<\/strong><\/th>\n<th style=\"width: 22%\" width=\"99\"><strong>Storage<\/strong><\/th>\n<th style=\"width: 52.6667%\" width=\"237\"><strong>Notes<\/strong><\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<th style=\"width: 25.3333%\" width=\"114\"><strong>DATE<\/strong><\/th>\n<th style=\"width: 22%\" width=\"99\">3 bytes<\/th>\n<th style=\"width: 52.6667%\" width=\"237\">Format: YYYY-MM-DD. Range: &#8216;1000-01-01&#8217; to &#8216;9999-12-31&#8217;<\/th>\n<\/tr>\n<tr>\n<th style=\"width: 25.3333%\" width=\"114\"><strong>TIME<\/strong><\/th>\n<td style=\"width: 22%\" width=\"99\">3 bytes<\/td>\n<td style=\"width: 52.6667%\" width=\"237\">Format: hh:mm:ss<\/td>\n<\/tr>\n<tr>\n<th style=\"width: 25.3333%\" width=\"114\"><strong>DATETIME<\/strong><\/th>\n<td style=\"width: 22%\" width=\"99\">5 bytes<\/td>\n<td style=\"width: 52.6667%\" width=\"237\">Format: YYYY-MM-DD hh:mm:ss. Range: &#8216;1000-01-01 00:00:00&#8217; to &#8216;9999-12-31 23:59:59&#8217;.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>&nbsp;<\/p>\n<p><strong>Table 2.5.2: Common MySQL data types: CHARACTER<\/strong><\/p>\n<table style=\"border-collapse: collapse;width: 68.5061%\" border=\"2\">\n<thead>\n<tr>\n<th style=\"width: 25.3333%\" width=\"114\"><strong>Data type<\/strong><\/th>\n<th style=\"width: 22%\" width=\"99\"><strong>Storage<\/strong><\/th>\n<th style=\"width: 52.6667%\" width=\"237\"><strong>Notes<\/strong><\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<th style=\"width: 25.3333%\" width=\"114\"><strong>CHAR(N)<\/strong><\/th>\n<th style=\"width: 22%\" width=\"99\"><em>N<\/em> bytes<\/th>\n<th style=\"width: 52.6667%\" width=\"237\">Fixed-length string of length <em>N<\/em>; 0 \u2264 <em>N<\/em> \u2264 255<\/th>\n<\/tr>\n<tr>\n<th style=\"width: 25.3333%\" width=\"114\"><strong>VARCHAR(N)<\/strong><\/th>\n<td style=\"width: 22%\" width=\"99\">Number of characters<br \/>\n+ 1 byte if N \u2264 255<br \/>\n+ 2 bytes if N &gt; 255<\/td>\n<td style=\"width: 52.6667%\" width=\"237\">Variable-length string with maximum <em>N<\/em> characters; 0 \u2264 <em>N<\/em> \u2264 65,535<\/td>\n<\/tr>\n<tr>\n<th style=\"width: 25.3333%\" width=\"114\"><strong>TEXT<\/strong><\/th>\n<td style=\"width: 22%\" width=\"99\">Number of characters<br \/>\n+ 2 bytes<\/td>\n<td style=\"width: 52.6667%\" width=\"237\">Variable-length string with maximum 65,535 characters<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Table 2.5.2: Common MySQL data types: INTEGER Data type Storage Notes TINYINT 1 byte Signed range: -128 to 127 Unsigned range: 0 to 255 SMALLINT 2 bytes Signed range: -32,768 &hellip; <a href=\"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/\" class=\"\">Read More<\/a><\/p>\n","protected":false},"author":1815,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_acf_changed":false,"footnotes":""},"class_list":["post-846","page","type-page","status-publish","hentry"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v23.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Data Types - Joann J. Ordille<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Data Types - Joann J. Ordille\" \/>\n<meta property=\"og:description\" content=\"Table 2.5.2: Common MySQL data types: INTEGER Data type Storage Notes TINYINT 1 byte Signed range: -128 to 127 Unsigned range: 0 to 255 SMALLINT 2 bytes Signed range: -32,768 &hellip; Read More\" \/>\n<meta property=\"og:url\" content=\"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/\" \/>\n<meta property=\"og:site_name\" content=\"Joann J. Ordille\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/\",\"url\":\"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/\",\"name\":\"Data Types - Joann J. Ordille\",\"isPartOf\":{\"@id\":\"https:\/\/sites.rutgers.edu\/joann-ordille\/#website\"},\"datePublished\":\"2026-10-13T02:40:04+00:00\",\"dateModified\":\"2026-10-13T02:40:04+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/sites.rutgers.edu\/joann-ordille\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Data Types\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/sites.rutgers.edu\/joann-ordille\/#website\",\"url\":\"https:\/\/sites.rutgers.edu\/joann-ordille\/\",\"name\":\"Joann J. Ordille\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/sites.rutgers.edu\/joann-ordille\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Data Types - Joann J. Ordille","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/","og_locale":"en_US","og_type":"article","og_title":"Data Types - Joann J. Ordille","og_description":"Table 2.5.2: Common MySQL data types: INTEGER Data type Storage Notes TINYINT 1 byte Signed range: -128 to 127 Unsigned range: 0 to 255 SMALLINT 2 bytes Signed range: -32,768 &hellip; Read More","og_url":"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/","og_site_name":"Joann J. Ordille","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/","url":"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/","name":"Data Types - Joann J. Ordille","isPartOf":{"@id":"https:\/\/sites.rutgers.edu\/joann-ordille\/#website"},"datePublished":"2026-10-13T02:40:04+00:00","dateModified":"2026-10-13T02:40:04+00:00","breadcrumb":{"@id":"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/sites.rutgers.edu\/joann-ordille\/data-types\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/sites.rutgers.edu\/joann-ordille\/"},{"@type":"ListItem","position":2,"name":"Data Types"}]},{"@type":"WebSite","@id":"https:\/\/sites.rutgers.edu\/joann-ordille\/#website","url":"https:\/\/sites.rutgers.edu\/joann-ordille\/","name":"Joann J. Ordille","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/sites.rutgers.edu\/joann-ordille\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"_links":{"self":[{"href":"https:\/\/sites.rutgers.edu\/joann-ordille\/wp-json\/wp\/v2\/pages\/846","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sites.rutgers.edu\/joann-ordille\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/sites.rutgers.edu\/joann-ordille\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/sites.rutgers.edu\/joann-ordille\/wp-json\/wp\/v2\/users\/1815"}],"replies":[{"embeddable":true,"href":"https:\/\/sites.rutgers.edu\/joann-ordille\/wp-json\/wp\/v2\/comments?post=846"}],"version-history":[{"count":1,"href":"https:\/\/sites.rutgers.edu\/joann-ordille\/wp-json\/wp\/v2\/pages\/846\/revisions"}],"predecessor-version":[{"id":847,"href":"https:\/\/sites.rutgers.edu\/joann-ordille\/wp-json\/wp\/v2\/pages\/846\/revisions\/847"}],"wp:attachment":[{"href":"https:\/\/sites.rutgers.edu\/joann-ordille\/wp-json\/wp\/v2\/media?parent=846"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}