{"id":18,"date":"2023-12-29T18:18:43","date_gmt":"2023-12-29T18:18:43","guid":{"rendered":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/?page_id=18"},"modified":"2023-12-29T19:32:29","modified_gmt":"2023-12-29T19:32:29","slug":"lesson-2-getting-started-with-mysql","status":"publish","type":"page","link":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/lesson-2-getting-started-with-mysql\/","title":{"rendered":"Lesson 2"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">Getting Started with MySQL<\/h2>\n\n\n\n<p class=\"\">In this lesson you will connect to MySQL and explore a database then return results from a table<\/p>\n\n\n\n<figure class=\"wp-embed-aspect-16-9 wp-has-aspect-ratio wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"Learn MySQL in 2024:Lesson 2 getting started with MySQL Shell and Workbench\" width=\"500\" height=\"281\" src=\"https:\/\/www.youtube.com\/embed\/QQhN6MUSM-U?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Commands used in this lesson include:<\/h3>\n\n\n\n<p class=\"\">\\sql &#8211; Switches the command shell over to SQL commands from JavaScript commands<\/p>\n\n\n\n<p class=\"\">\\connect mysql:\/\/demo-user@localhost:3306 &#8211; Connects to the MySQL server on localhost port 3306<\/p>\n\n\n\n<p class=\"\">SHOW DATABASES; &#8211; Shows the databases on your server that you are connected to<\/p>\n\n\n\n<p class=\"\">USE demo; &#8211; Switches to the sakili database<\/p>\n\n\n\n<p class=\"\">SHOW TABLES; &#8211; Shows the tables in the sakili database<\/p>\n\n\n\n<p class=\"\">SELECT * FROM actors; &#8211; Returns all the rows and columns in the actors table<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Getting Started with MySQL In this lesson you will connect to MySQL and explore a database then return results from a table Commands used in this lesson include: \\sql &#8211; Switches the command shell over to SQL commands from JavaScript commands \\connect mysql:\/\/demo-user@localhost:3306 &#8211; Connects to the MySQL server on localhost port 3306 SHOW DATABASES; [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"nf_dc_page":"","om_disable_all_campaigns":false,"footnotes":""},"class_list":["post-18","page","type-page","status-publish","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Lesson 2 - Free SQL Class<\/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:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/lesson-2-getting-started-with-mysql\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Lesson 2 - Free SQL Class\" \/>\n<meta property=\"og:description\" content=\"Getting Started with MySQL In this lesson you will connect to MySQL and explore a database then return results from a table Commands used in this lesson include: sql &#8211; Switches the command shell over to SQL commands from JavaScript commands connect mysql:\/\/demo-user@localhost:3306 &#8211; Connects to the MySQL server on localhost port 3306 SHOW DATABASES; [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/lesson-2-getting-started-with-mysql\/\" \/>\n<meta property=\"og:site_name\" content=\"Free SQL Class\" \/>\n<meta property=\"article:modified_time\" content=\"2023-12-29T19:32:29+00:00\" \/>\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=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/freesqlclass.com\\\/learn\\\/welcome-to-the-free-sql-class\\\/lesson-2-getting-started-with-mysql\\\/\",\"url\":\"https:\\\/\\\/freesqlclass.com\\\/learn\\\/welcome-to-the-free-sql-class\\\/lesson-2-getting-started-with-mysql\\\/\",\"name\":\"Lesson 2 - Free SQL Class\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/freesqlclass.com\\\/learn\\\/welcome-to-the-free-sql-class\\\/#website\"},\"datePublished\":\"2023-12-29T18:18:43+00:00\",\"dateModified\":\"2023-12-29T19:32:29+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/freesqlclass.com\\\/learn\\\/welcome-to-the-free-sql-class\\\/lesson-2-getting-started-with-mysql\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/freesqlclass.com\\\/learn\\\/welcome-to-the-free-sql-class\\\/lesson-2-getting-started-with-mysql\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/freesqlclass.com\\\/learn\\\/welcome-to-the-free-sql-class\\\/lesson-2-getting-started-with-mysql\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/freesqlclass.com\\\/learn\\\/welcome-to-the-free-sql-class\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Lesson 2\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/freesqlclass.com\\\/learn\\\/welcome-to-the-free-sql-class\\\/#website\",\"url\":\"https:\\\/\\\/freesqlclass.com\\\/learn\\\/welcome-to-the-free-sql-class\\\/\",\"name\":\"Free SQL Class\",\"description\":\"Learn SQL using MySQL and SQL Server for Free in 2024\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/freesqlclass.com\\\/learn\\\/welcome-to-the-free-sql-class\\\/?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":"Lesson 2 - Free SQL Class","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:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/lesson-2-getting-started-with-mysql\/","og_locale":"en_US","og_type":"article","og_title":"Lesson 2 - Free SQL Class","og_description":"Getting Started with MySQL In this lesson you will connect to MySQL and explore a database then return results from a table Commands used in this lesson include: sql &#8211; Switches the command shell over to SQL commands from JavaScript commands connect mysql:\/\/demo-user@localhost:3306 &#8211; Connects to the MySQL server on localhost port 3306 SHOW DATABASES; [&hellip;]","og_url":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/lesson-2-getting-started-with-mysql\/","og_site_name":"Free SQL Class","article_modified_time":"2023-12-29T19:32:29+00:00","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/lesson-2-getting-started-with-mysql\/","url":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/lesson-2-getting-started-with-mysql\/","name":"Lesson 2 - Free SQL Class","isPartOf":{"@id":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/#website"},"datePublished":"2023-12-29T18:18:43+00:00","dateModified":"2023-12-29T19:32:29+00:00","breadcrumb":{"@id":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/lesson-2-getting-started-with-mysql\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/lesson-2-getting-started-with-mysql\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/lesson-2-getting-started-with-mysql\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/"},{"@type":"ListItem","position":2,"name":"Lesson 2"}]},{"@type":"WebSite","@id":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/#website","url":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/","name":"Free SQL Class","description":"Learn SQL using MySQL and SQL Server for Free in 2024","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/wp-json\/wp\/v2\/pages\/18","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/wp-json\/wp\/v2\/comments?post=18"}],"version-history":[{"count":3,"href":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/wp-json\/wp\/v2\/pages\/18\/revisions"}],"predecessor-version":[{"id":37,"href":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/wp-json\/wp\/v2\/pages\/18\/revisions\/37"}],"wp:attachment":[{"href":"https:\/\/freesqlclass.com\/learn\/welcome-to-the-free-sql-class\/wp-json\/wp\/v2\/media?parent=18"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}