{"id":108393,"date":"2022-03-28T11:00:00","date_gmt":"2022-03-28T08:00:00","guid":{"rendered":"https:\/\/examples.javacodegeeks.com\/?p=108393"},"modified":"2022-03-29T12:51:45","modified_gmt":"2022-03-29T09:51:45","slug":"what-is-the-difference-between-sql-mysql-sqlite-sqlite3","status":"publish","type":"post","link":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql","title":{"rendered":"SQL and an introduction to SQLite, SQLite3, and MySQL"},"content":{"rendered":"<p>In this article, we will show you the difference between SQL, MySQL, Sqlite, Sqlite3. SQL stands for Structured Query Language. SQL is an example of 4GL or Fourth Generation Language. <\/p>\n<\/p>\n<h2>1.1 First-Generation Language<\/h2>\n<p>First-generation languages were machine languages that involved entering instructions to a computer in the form of bits or binary digits, represented by 1s and 0s, on and off, true or false. As a result, programming or the creation of instructions for the computer proved to be very time-consuming, and very complex. <\/p>\n<h2>1.2 Second-Generation Language<\/h2>\n<p>Second-generation languages or assembly languages were then developed in which mnemonics or representations in English words are used to represent instructions, such as ADD, SUB, MOV, JMP. This allowed for easier visualization of the logic of the program but was still difficult because each assembly language instruction was assembled by an assembler into machine language, so there was usually a one-to-one correspondence between assembly language and machine language which is the only language a computer understands.<\/p>\n<h2>1.3 Third-Generation Language<\/h2>\n<p>Third-generation languages are a huge leap forward which includes languages such as C, C++, Basic, Fortran, Cobol, Java, Python, PHP, etc. in which one statement in these languages will translate into many assembly language and machine language instructions. As a result, more programmers or the authors of these instructions can dictate what a computer can do and how to do it.<\/p>\n<h2>1.4 Fourth-Generation Language<\/h2>\n<p>Fourth Generation Languages, such as SQL, direct a computer on what to do in terms of manipulating a database but not how to do it.<\/p>\n<h2>1.5 Fifth-Generation Language<\/h2>\n<p>Finally, Fifth Generation Languages, such as Prolog (&#8220;PRO&#8221;gramming &#8220;LOG&#8221;ic), allow for the creation of facts and rules on how to manipulate the facts.<\/p>\n<h2>2. SQL and Relational Databases<\/h2>\n<p>According to <a href=\"https:\/\/en.wikipedia.org\/wiki\/SQL\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/en.wikipedia.org\/wiki\/SQL<\/a>, Donald D. Chamberlin and Raymond F. Boyce first developed SQL while working for IBM to implement the relational model of Edgar F. Codd in the early 1970s, <\/p>\n<p>The relational model of data representation involves organizing data into tables which are themselves made up of rows of columns. Each table would be used to house entities. Each row would be an instance of an entity. Rows contain fields or particular characteristics or attributes of that entity.<\/p>\n<p>The relational model of data representation also allows for some relations, links, or correspondences between tables or entities.<\/p>\n<p>Finally, a relational database can be defined as a collection of such tables which are somehow related. Relational databases also include objects, in addition to tables, such as indices which allow for efficient retrieval of sorted data, permissions that control access to the data, and triggers that allow for the change to the data when certain events or criteria of the data are met.<\/p>\n<p>Relational Database Management Systems (RDBMS) are built around the concept of relational databases to allow for the creation, manipulation, and visualization of the data.<\/p>\n<p>Many RDBMS are in existence. IBM DB2, IBM Informix, Oracle, Microsoft SQLServer, PostgreSQL, Sybase, Microsoft Access, MySQL, SQLite, and SQLite3 come to mind.<\/p>\n<p>MySQL, like Microsoft SQLServer, PostgresSQL, Oracle, Sybase, IBM DB2, is built around a Server-Client architecture. The Server is a computer or computer system, which has server software, that executes the SQL Statements forwarded to by the Client. The Client can be on the same computer with client software but typically the server is a dedicated computer due to the amount of work that the server must perform including handling requests from many clients. Websites, as well as desktop applications that require data, are usually consumers or clients of Server-based databases.<\/p>\n<p>SQLite or SQLite3 do not require a server to store its data. Data is stored in a single file and therefore, dedicated to one user at a time.<\/p>\n<p>SQLite use has exploded in step with the ubiquity of mobile devices. Due to its small digital footprint, it is perfectly suited for these devices. Databases is also typically housed in a single file with extensions such as .sqlite, .sqlite3, .db, .db3<\/p>\n<p>SQLite3 differs from its predecessors (SQLite and SQLite2) in that numbers and BLOBs (Binary Large Objects) are stored in their native formats as opposed to its predecessors in which data is stored as strings. This may result in smaller database sizes.<div style=\"display:inline-block; margin: 15px 0;\"> <div id=\"adngin-JavaCodeGeeks_incontent_video-0\" style=\"display:inline-block;\"><\/div> <\/div><\/p>\n<p>SQL is what is used to provide instructions to MySQL, SQLite, SQLite, Oracle, SQLServer, databases. <\/p>\n<h2>3. SQL &#8211; The language<\/h2>\n<p>SQL is made up of many statements which fall into 5 major sublanguages:<\/p>\n<p>\u2022   Data Definition Language (DDL)<br \/>\u2022 Data Manipulation Language (DML)<br \/>\u2022 Data Query Language (DQL)<br \/>\u2022 Data Control Language (DCL)<br \/>\u2022 Transaction Control Language<\/p>\n<h2>4. Data Definition Language<\/h2>\n<p>Data Definition Language is used to define the database and the constructs with which the data is stored. Below are some examples<br \/> CREATE DATABASE<br \/>             Creates a database<br \/> DROP DATABASE<br \/>             Delete (drop) a database<br \/> CREATE TABLE<br \/>             Creates a table by providing field names, field types, and other attributes of Fields<br \/> ALTER TABLE <br \/>            Modify the structure of a table<br \/> DROP TABLE<br \/>            Delete (drop) a table           <br \/>\u2003<br \/>The following will illustrate the use of these SQL Statements:     <\/p>\n<pre class=\"brush:plain\">\/*  \n    mySQL: \n*\/\nCREATE DATABASE baseball;\nCREATE TABLE baseball.teams (id int primary key auto_increment, City varchar(30), Name varchar(30), Manager varchar(30));\n<\/pre>\n<figure class=\"wp-block-image size-full is-resized\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-1.jpg\"><img decoding=\"async\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-1.jpg\" alt=\"\" class=\"wp-image-108672\" width=\"624\" height=\"338\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-1.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-1-300x163.jpg 300w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>MySQL: CREATE DATABASE &#8211; CREATE TABLE<\/figcaption><\/figure>\n<pre class=\"brush:plain\">ALTER TABLE baseball. teams DROP COLUMN Manager;\n<\/pre>\n<figure class=\"wp-block-image size-full is-resized\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-2.jpg\"><img decoding=\"async\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-2.jpg\" alt=\"\" class=\"wp-image-108673\" width=\"624\" height=\"331\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-2.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-2-300x160.jpg 300w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-2-620x330.jpg 620w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>MySQL: ALTER TABLE DROP COLUMN<\/figcaption><\/figure>\n<p><\/p>\n<pre class=\"brush:plain\">ALTER TABLE baseball.teams ADD Manager INTEGER;\n<\/pre>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-3.jpg\"><img decoding=\"async\" width=\"624\" height=\"332\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-3.jpg\" alt=\"\" class=\"wp-image-108674\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-3.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-3-300x160.jpg 300w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-3-620x330.jpg 620w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>MySQL: ALTER TABLE ADD<\/figcaption><\/figure>\n<pre class=\"brush:plain\">DROP DATABASE baseball;\n<\/pre>\n<figure class=\"wp-block-image size-full is-resized\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-4.jpg\"><img decoding=\"async\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-4.jpg\" alt=\"\" class=\"wp-image-108675\" width=\"624\" height=\"530\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-4.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-4-300x255.jpg 300w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>MySQL: DROP TABLE<\/figcaption><\/figure>\n<div class=\"wp-block-group\">\n<div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<pre class=\"brush:plain\">\/*\n   sqlite3:\n       These statements are not available in SQLite3, SQLite\n\n      CREATE DATABASE baseball;\n      TRUNCATE TABLE teams;\n\n      below is illustrated the creation of the baseball database\n*\/\n<\/pre>\n<\/div>\n<\/div>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-5.jpg\"><img decoding=\"async\" width=\"513\" height=\"286\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-5.jpg\" alt=\"\" class=\"wp-image-108676\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-5.jpg 513w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-5-300x167.jpg 300w\" sizes=\"(max-width: 513px) 100vw, 513px\" \/><\/a><figcaption>SQLITE: CREATE A DATABASE<\/figcaption><\/figure>\n<pre class=\"brush:plain\">CREATE TABLE teams (id integer primary key autoincrement, City varchar(30), Name varchar(30), Manager varchar(30));\nALTER TABLE teams DROP COLUMN Manager;\nALTER TABLE teams ADD Manager integer;\n<\/pre>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-6.jpg\"><img decoding=\"async\" width=\"624\" height=\"282\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-6.jpg\" alt=\"\" class=\"wp-image-108677\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-6.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-6-300x136.jpg 300w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>SQLITE: CREATE TABLE, ALTER TABLE, INSERT<\/figcaption><\/figure>\n<pre class=\"brush:plain\">DROP TABLE teams;<br><\/pre>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-7.jpg\"><img decoding=\"async\" width=\"624\" height=\"37\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-7.jpg\" alt=\"\" class=\"wp-image-108678\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-7.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-7-300x18.jpg 300w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-7-620x37.jpg 620w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>SQLITE: DROP TABLE<\/figcaption><\/figure>\n<h2>5. Data Manipulation Language<\/h2>\n<p>Data Manipulation Language is used to add, delete, modify data in the database<br \/>       INSERT <br \/>               Add rows to a table <br \/>       UPDATE<br \/>               Modify rows to a table<br \/>       DELETE <br \/>               Remove rows from a table<\/p>\n<pre class=\"brush:plain\">\/*          mysql:\n*\/\ntruncate baseball.teams;\ninsert into baseball.teams (City, Name) values ('Baltimore', 'Orioles');\ninsert into baseball.teams (City, Name) values ('Boston', 'Red Sox');\ninsert into baseball.teams (City, Name) values ('New York', 'Yankees');\ninsert into baseball.teams (City, Name) values ('Tampa Bay', 'Rays');\ninsert into baseball.teams (City, Name) values ('Toronto', 'Blue Jays');\n<\/pre>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-8.jpg\"><img decoding=\"async\" width=\"624\" height=\"336\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-8.jpg\" alt=\"\" class=\"wp-image-108679\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-8.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-8-300x162.jpg 300w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><\/figure>\n<pre class=\"brush:plain\">update baseball.teams set Name = 'Mets' where City = 'New York';\n<\/pre>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-9.jpg\"><img decoding=\"async\" width=\"624\" height=\"333\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-9.jpg\" alt=\"\" class=\"wp-image-108680\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-9.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-9-300x160.jpg 300w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-9-620x330.jpg 620w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>MySQL: UPDATE row<\/figcaption><\/figure>\n<pre class=\"brush:plain\">delete from baseball.teams where City = 'Toronto';\n<\/pre>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-10.jpg\"><img decoding=\"async\" width=\"624\" height=\"332\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-10.jpg\" alt=\"\" class=\"wp-image-108681\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-10.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-10-300x160.jpg 300w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-10-620x330.jpg 620w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>MySQL: DELETE row<\/figcaption><\/figure>\n<pre class=\"brush:plain\">\/* \n     sqlite3:\n     These statements are unavailable in SQLite3\n\n     TRUNCATE TABLE teams;\n*\/\n     insert into teams (City, Name) values ('Baltimore', 'Orioles');\n     insert into teams (City, Name) values ('Boston', 'Red Sox');\n     insert into teams (City, Name) values ('New York', 'Yankees');\n     insert into teams (City, Name) values ('Tampa Bay', 'Rays');\n     insert into teams (City, Name) values ('Toronto', 'Blue Jays'); \n     update teams set Name = 'Mets' where City = 'New York';\n     delete from teams where City = 'Toronto';\n\n <\/pre>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-12.jpg\"><img decoding=\"async\" width=\"624\" height=\"282\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-12.jpg\" alt=\"\" class=\"wp-image-108682\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-12.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-12-300x136.jpg 300w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>SQLITE: INSERT UPDATE row<\/figcaption><\/figure>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-13.jpg\"><img decoding=\"async\" width=\"624\" height=\"66\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-13.jpg\" alt=\"\" class=\"wp-image-108683\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-13.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-13-300x32.jpg 300w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-13-620x66.jpg 620w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>SQLITE: DELETE row<\/figcaption><\/figure>\n<h2>6. Data Query Language<\/h2>\n<p>Data Query Language is used to retrieve information from the database<\/p>\n<pre class=\"brush:plain\">\/*   \n     mysql:\n*\/\nselect * from baseball.teams;\nselect * from baseball.teams where City = 'Boston';\n<\/pre>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-14.jpg\"><img decoding=\"async\" width=\"624\" height=\"331\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-14.jpg\" alt=\"\" class=\"wp-image-108684\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-14.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-14-300x160.jpg 300w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-14-620x330.jpg 620w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>MySQL: SELECT<\/figcaption><\/figure>\n<pre class=\"brush:plain\">\/*   sqlite3\n*\/\nselect * from teams;\nselect * from teams where City = 'Boston';\n<\/pre>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-15.jpg\"><img decoding=\"async\" width=\"624\" height=\"169\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-15.jpg\" alt=\"\" class=\"wp-image-108685\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-15.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-15-300x81.jpg 300w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-15-620x169.jpg 620w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>SQLITE: SELECT<\/figcaption><\/figure>\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-16.jpg\"><img decoding=\"async\" width=\"624\" height=\"29\" src=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-16.jpg\" alt=\"\" class=\"wp-image-108686\" srcset=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-16.jpg 624w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-16-300x14.jpg 300w, https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/image-16-620x29.jpg 620w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption>SQLITE: SELECT<\/figcaption><\/figure>\n<h2>7. Data Control Language<\/h2>\n<p>Data Control Language is used to control access to the database<br \/>     examples are GRANT and REVOKE<br \/>     GRANT will set the permissions for a particular user for a particular operation to a particular <br \/>            database object<br \/>     REVOKE is the opposite of GRANT and remove such permission\n<\/p>\n<h2>8. Transaction Control Language<\/h2>\n<p>Transaction Control Language is used to determine the outcome of the transaction to the database<br \/>     examples are COMMIT and ROLLBACK<br \/>     COMMIT allows the transaction to be Permanently saved to the database<br \/>     ROLLBACK allows the transaction to be ignored and will not be saved to the database<\/p>\n<h2>9. Summary<\/h2>\n<p>This article is an introduction to SQL and MySQL difference and how it is used to create a very simple data model to store information. There are more complex uses for SQL which the reader may choose to explore, such as:<\/p>\n<p>            Multi-table data models and joining tables using foreign keys<\/p>\n<p>            Creating Stored Procedures and functions<\/p>\n<p>            Using SQL from Applications written in Java, Python, PHP, C\/C++, Ruby, etc.<\/p>\n<div class=\"download\"><strong>Download<\/strong><br \/>\nYou can download the scripts containing the SQL Statements for sql and mysql differences used in this article: <a href=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/03\/mysql_sqlite_scripts.zip\"><strong>What is the difference between SQL, MySql, Sqlite, Sqlite3<\/strong><\/a><\/div>\n","protected":false},"excerpt":{"rendered":"<p>In this article, we will show you the difference between SQL, MySQL, Sqlite, Sqlite3. SQL stands for Structured Query Language. SQL is an example of 4GL or Fourth Generation Language. 1.1 First-Generation Language First-generation languages were machine languages that involved entering instructions to a computer in the form of bits or binary digits, represented by &hellip;<\/p>\n","protected":false},"author":246,"featured_media":1204,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[53],"tags":[],"class_list":["post-108393","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-sql"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>SQL and an introduction to SQLite, SQLite3, and MySQL - Java Code Geeks<\/title>\n<meta name=\"description\" content=\"In this article, we will show you the difference between SQL, MySQL, Sqlite, Sqlite3. SQL stands for Structured Query Language. SQL is an example of 4GL\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"SQL and an introduction to SQLite, SQLite3, and MySQL - Java Code Geeks\" \/>\n<meta property=\"og:description\" content=\"In this article, we will show you the difference between SQL, MySQL, Sqlite, Sqlite3. SQL stands for Structured Query Language. SQL is an example of 4GL\" \/>\n<meta property=\"og:url\" content=\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/\" \/>\n<meta property=\"og:site_name\" content=\"Examples Java Code Geeks\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/javacodegeeks\" \/>\n<meta property=\"article:published_time\" content=\"2022-03-28T08:00:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-03-29T09:51:45+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2012\/12\/java-logo.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"150\" \/>\n\t<meta property=\"og:image:height\" content=\"150\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Frank Yee\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@javacodegeeks\" \/>\n<meta name=\"twitter:site\" content=\"@javacodegeeks\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Frank Yee\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"10 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/\"},\"author\":{\"name\":\"Frank Yee\",\"@id\":\"https:\/\/examples.javacodegeeks.com\/#\/schema\/person\/323f1a54a42065a9c5493111ab1ab82b\"},\"headline\":\"SQL and an introduction to SQLite, SQLite3, and MySQL\",\"datePublished\":\"2022-03-28T08:00:00+00:00\",\"dateModified\":\"2022-03-29T09:51:45+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/\"},\"wordCount\":1121,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/examples.javacodegeeks.com\/#organization\"},\"image\":{\"@id\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2012\/12\/java-logo.jpg\",\"articleSection\":[\"sql\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/\",\"url\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/\",\"name\":\"SQL and an introduction to SQLite, SQLite3, and MySQL - Java Code Geeks\",\"isPartOf\":{\"@id\":\"https:\/\/examples.javacodegeeks.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2012\/12\/java-logo.jpg\",\"datePublished\":\"2022-03-28T08:00:00+00:00\",\"dateModified\":\"2022-03-29T09:51:45+00:00\",\"description\":\"In this article, we will show you the difference between SQL, MySQL, Sqlite, Sqlite3. SQL stands for Structured Query Language. SQL is an example of 4GL\",\"breadcrumb\":{\"@id\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#primaryimage\",\"url\":\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2012\/12\/java-logo.jpg\",\"contentUrl\":\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2012\/12\/java-logo.jpg\",\"width\":150,\"height\":150,\"caption\":\"Bipartite Graph\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/examples.javacodegeeks.com\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Java Development\",\"item\":\"https:\/\/examples.javacodegeeks.com\/category\/java-development\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Core Java\",\"item\":\"https:\/\/examples.javacodegeeks.com\/category\/java-development\/core-java\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"sql\",\"item\":\"https:\/\/examples.javacodegeeks.com\/category\/java-development\/core-java\/sql\/\"},{\"@type\":\"ListItem\",\"position\":5,\"name\":\"SQL and an introduction to SQLite, SQLite3, and MySQL\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/examples.javacodegeeks.com\/#website\",\"url\":\"https:\/\/examples.javacodegeeks.com\/\",\"name\":\"Java Code Geeks\",\"description\":\"Java Examples and Code Snippets\",\"publisher\":{\"@id\":\"https:\/\/examples.javacodegeeks.com\/#organization\"},\"alternateName\":\"JCG\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/examples.javacodegeeks.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/examples.javacodegeeks.com\/#organization\",\"name\":\"Exelixis Media P.C.\",\"url\":\"https:\/\/examples.javacodegeeks.com\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/examples.javacodegeeks.com\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/06\/exelixis-logo.png\",\"contentUrl\":\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/06\/exelixis-logo.png\",\"width\":864,\"height\":246,\"caption\":\"Exelixis Media P.C.\"},\"image\":{\"@id\":\"https:\/\/examples.javacodegeeks.com\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/javacodegeeks\",\"https:\/\/x.com\/javacodegeeks\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/examples.javacodegeeks.com\/#\/schema\/person\/323f1a54a42065a9c5493111ab1ab82b\",\"name\":\"Frank Yee\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/examples.javacodegeeks.com\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/02\/frank.yee_-96x96.jpg\",\"contentUrl\":\"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/02\/frank.yee_-96x96.jpg\",\"caption\":\"Frank Yee\"},\"description\":\"Frank holds a Bachelor of Science in Biology from The City University of New York (The City College of New York) and a Bachelor of Arts in Computer Science from The City University of New York (Hunter College). As an undergraduate, he had taken courses where programs were written in Fortran, Basic, Pascal, COBOL, and Assembly Language for the IBM 4341 Mainframe. He has been a software developer for over 30 years having built desktop apps, mobile apps and web apps. He has built software in C\/C++, VisualBasic, TCL, Java, PHP, XML\/XSLT, Perl, Shell Scripting and Python. Frank was also an educator in The City University of New York (Borough of Manhattan Community College, New York City College of Technology) having taught courses in Pascal, VisualBasic, C++ for over 10 years. Finally, he has recently helped students create programs in Lisp, R, Masm, Haskell, Scheme and Prolog.\",\"sameAs\":[\"http:\/\/www.linkedin.com\/in\/frankyee\"],\"url\":\"https:\/\/examples.javacodegeeks.com\/author\/frank-yee\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"SQL and an introduction to SQLite, SQLite3, and MySQL - Java Code Geeks","description":"In this article, we will show you the difference between SQL, MySQL, Sqlite, Sqlite3. SQL stands for Structured Query Language. SQL is an example of 4GL","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:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/","og_locale":"en_US","og_type":"article","og_title":"SQL and an introduction to SQLite, SQLite3, and MySQL - Java Code Geeks","og_description":"In this article, we will show you the difference between SQL, MySQL, Sqlite, Sqlite3. SQL stands for Structured Query Language. SQL is an example of 4GL","og_url":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/","og_site_name":"Examples Java Code Geeks","article_publisher":"https:\/\/www.facebook.com\/javacodegeeks","article_published_time":"2022-03-28T08:00:00+00:00","article_modified_time":"2022-03-29T09:51:45+00:00","og_image":[{"width":150,"height":150,"url":"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2012\/12\/java-logo.jpg","type":"image\/jpeg"}],"author":"Frank Yee","twitter_card":"summary_large_image","twitter_creator":"@javacodegeeks","twitter_site":"@javacodegeeks","twitter_misc":{"Written by":"Frank Yee","Est. reading time":"10 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#article","isPartOf":{"@id":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/"},"author":{"name":"Frank Yee","@id":"https:\/\/examples.javacodegeeks.com\/#\/schema\/person\/323f1a54a42065a9c5493111ab1ab82b"},"headline":"SQL and an introduction to SQLite, SQLite3, and MySQL","datePublished":"2022-03-28T08:00:00+00:00","dateModified":"2022-03-29T09:51:45+00:00","mainEntityOfPage":{"@id":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/"},"wordCount":1121,"commentCount":0,"publisher":{"@id":"https:\/\/examples.javacodegeeks.com\/#organization"},"image":{"@id":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#primaryimage"},"thumbnailUrl":"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2012\/12\/java-logo.jpg","articleSection":["sql"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/","url":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/","name":"SQL and an introduction to SQLite, SQLite3, and MySQL - Java Code Geeks","isPartOf":{"@id":"https:\/\/examples.javacodegeeks.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#primaryimage"},"image":{"@id":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#primaryimage"},"thumbnailUrl":"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2012\/12\/java-logo.jpg","datePublished":"2022-03-28T08:00:00+00:00","dateModified":"2022-03-29T09:51:45+00:00","description":"In this article, we will show you the difference between SQL, MySQL, Sqlite, Sqlite3. SQL stands for Structured Query Language. SQL is an example of 4GL","breadcrumb":{"@id":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#primaryimage","url":"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2012\/12\/java-logo.jpg","contentUrl":"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2012\/12\/java-logo.jpg","width":150,"height":150,"caption":"Bipartite Graph"},{"@type":"BreadcrumbList","@id":"https:\/\/examples.javacodegeeks.com\/sql-and-an-introduction-to-sqlite-sqlite3-and-mysql\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/examples.javacodegeeks.com\/"},{"@type":"ListItem","position":2,"name":"Java Development","item":"https:\/\/examples.javacodegeeks.com\/category\/java-development\/"},{"@type":"ListItem","position":3,"name":"Core Java","item":"https:\/\/examples.javacodegeeks.com\/category\/java-development\/core-java\/"},{"@type":"ListItem","position":4,"name":"sql","item":"https:\/\/examples.javacodegeeks.com\/category\/java-development\/core-java\/sql\/"},{"@type":"ListItem","position":5,"name":"SQL and an introduction to SQLite, SQLite3, and MySQL"}]},{"@type":"WebSite","@id":"https:\/\/examples.javacodegeeks.com\/#website","url":"https:\/\/examples.javacodegeeks.com\/","name":"Java Code Geeks","description":"Java Examples and Code Snippets","publisher":{"@id":"https:\/\/examples.javacodegeeks.com\/#organization"},"alternateName":"JCG","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/examples.javacodegeeks.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/examples.javacodegeeks.com\/#organization","name":"Exelixis Media P.C.","url":"https:\/\/examples.javacodegeeks.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/examples.javacodegeeks.com\/#\/schema\/logo\/image\/","url":"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/06\/exelixis-logo.png","contentUrl":"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/06\/exelixis-logo.png","width":864,"height":246,"caption":"Exelixis Media P.C."},"image":{"@id":"https:\/\/examples.javacodegeeks.com\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/javacodegeeks","https:\/\/x.com\/javacodegeeks"]},{"@type":"Person","@id":"https:\/\/examples.javacodegeeks.com\/#\/schema\/person\/323f1a54a42065a9c5493111ab1ab82b","name":"Frank Yee","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/examples.javacodegeeks.com\/#\/schema\/person\/image\/","url":"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/02\/frank.yee_-96x96.jpg","contentUrl":"https:\/\/examples.javacodegeeks.com\/wp-content\/uploads\/2022\/02\/frank.yee_-96x96.jpg","caption":"Frank Yee"},"description":"Frank holds a Bachelor of Science in Biology from The City University of New York (The City College of New York) and a Bachelor of Arts in Computer Science from The City University of New York (Hunter College). As an undergraduate, he had taken courses where programs were written in Fortran, Basic, Pascal, COBOL, and Assembly Language for the IBM 4341 Mainframe. He has been a software developer for over 30 years having built desktop apps, mobile apps and web apps. He has built software in C\/C++, VisualBasic, TCL, Java, PHP, XML\/XSLT, Perl, Shell Scripting and Python. Frank was also an educator in The City University of New York (Borough of Manhattan Community College, New York City College of Technology) having taught courses in Pascal, VisualBasic, C++ for over 10 years. Finally, he has recently helped students create programs in Lisp, R, Masm, Haskell, Scheme and Prolog.","sameAs":["http:\/\/www.linkedin.com\/in\/frankyee"],"url":"https:\/\/examples.javacodegeeks.com\/author\/frank-yee\/"}]}},"_links":{"self":[{"href":"https:\/\/examples.javacodegeeks.com\/wp-json\/wp\/v2\/posts\/108393","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/examples.javacodegeeks.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/examples.javacodegeeks.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/examples.javacodegeeks.com\/wp-json\/wp\/v2\/users\/246"}],"replies":[{"embeddable":true,"href":"https:\/\/examples.javacodegeeks.com\/wp-json\/wp\/v2\/comments?post=108393"}],"version-history":[{"count":0,"href":"https:\/\/examples.javacodegeeks.com\/wp-json\/wp\/v2\/posts\/108393\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/examples.javacodegeeks.com\/wp-json\/wp\/v2\/media\/1204"}],"wp:attachment":[{"href":"https:\/\/examples.javacodegeeks.com\/wp-json\/wp\/v2\/media?parent=108393"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/examples.javacodegeeks.com\/wp-json\/wp\/v2\/categories?post=108393"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/examples.javacodegeeks.com\/wp-json\/wp\/v2\/tags?post=108393"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}