[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"doc-seo-572206-105":3,"detail-sidebar-cat-1-en-105":81,"doc-detail-572206-en":127},{"code":4,"msg":5,"data":6},0,"ok",{"site_id":7,"language":8,"slug":9,"title":10,"keywords":11,"description":12,"schema_data":13,"social_meta":74,"head_meta":76,"extra_data":78,"updated_unix":80},105,"en","csce-156-lab-07-sql-i-handout","CSCE 156 - Lab 07: SQL I - Handout","","CSCE 156 Lab 07: SQL I handout guides students through preparing a MySQL environment and working with the Albums database. The lab focuses on connecting to a remote MySQL server via command line, importing the provided Albums.sql file, verifying installation with SHOW TABLES, and inspecting table schemas using DESCRIBE. It also introduces completing a worksheet with instructor sign-off and provides optional support via MySQL Workbench for running queries using a GUI.",{"@graph":14,"@context":73},[15,34,56],{"@type":16,"itemListElement":17},"BreadcrumbList",[18,23,27,31],{"item":19,"name":20,"@type":21,"position":22},"https://docshare.wps.com","Home","ListItem",1,{"item":24,"name":25,"@type":21,"position":26},"https://docshare.wps.com/template/","Template",2,{"item":28,"name":29,"@type":21,"position":30},"https://docshare.wps.com/template/presentations/","Presentations",3,{"item":32,"name":10,"@type":21,"position":33},"https://docshare.wps.com/template/csce-156-lab-07-sql-i-handout/572206/",4,{"url":32,"name":10,"@type":35,"image":36,"author":41,"headline":10,"publisher":44,"fileFormat":47,"inLanguage":8,"description":12,"dateModified":48,"datePublished":49,"encodingFormat":47,"isAccessibleForFree":50,"interactionStatistic":51},"DigitalDocument",{"url":37,"@type":38,"width":39,"height":40},"https://docshare.wps.com/thumbnails/csce-156-lab-07-sql-i-handout/572206.png","ImageObject",442,249,{"name":42,"@type":43},"นรินทร์","Person",{"url":19,"name":45,"@type":46},"DocShare","Organization","application/pdf","2026-10-21","2026-10-13",true,{"@type":52,"interactionType":53,"userInteractionCount":55},"InteractionCounter",{"@type":54},"ViewAction",7,{"@type":57,"mainEntity":58},"FAQPage",[59,65,69],{"name":60,"@type":61,"acceptedAnswer":62},"How do you import the Albums database into the CSE MySQL environment?","Question",{"text":63,"@type":64},"Download Albums.sql, do not modify it, connect through PuTTY, then run the mysql command that redirects the Albums.sql contents into the mysql command line to create tables and insert data.","Answer",{"name":66,"@type":61,"acceptedAnswer":67},"What commands confirm that the database was installed correctly and that tables exist?",{"text":68,"@type":64},"Use SHOW TABLES to list the six Albums-related tables, and use DESCRIBE TableName to view the structure of a specific table.",{"name":70,"@type":61,"acceptedAnswer":71},"What is the alternative to using the command line client for running SQL queries?",{"text":72,"@type":64},"MySQL Workbench provides a GUI client where you launch the app, open a connection, enter host name and credentials, and then run queries from the interface.","https://schema.org",{"og:url":32,"og:type":75,"og:title":10,"og:site_name":45,"og:description":12},"article",{"robots":77,"canonical":32},"index,follow",{"doc_id":79,"site_id":7},572206,1792338209,{"code":4,"msg":82,"data":83},"success",[84,88,93,98,103,108,113,118,123],{"id":85,"doc_module":22,"doc_module_name":25,"category_name":29,"show_sort_weight":86,"slug":87},11,90,"presentations",{"id":89,"doc_module":22,"doc_module_name":25,"category_name":90,"show_sort_weight":91,"slug":92},12,"Resumes",80,"resumes",{"id":94,"doc_module":22,"doc_module_name":25,"category_name":95,"show_sort_weight":96,"slug":97},14,"Invoices",70,"invoices",{"id":99,"doc_module":22,"doc_module_name":25,"category_name":100,"show_sort_weight":101,"slug":102},15,"Posters",60,"posters",{"id":104,"doc_module":22,"doc_module_name":25,"category_name":105,"show_sort_weight":106,"slug":107},16,"Social Media",50,"social-media",{"id":109,"doc_module":22,"doc_module_name":25,"category_name":110,"show_sort_weight":111,"slug":112},17,"Forms",40,"forms",{"id":114,"doc_module":22,"doc_module_name":25,"category_name":115,"show_sort_weight":116,"slug":117},18,"Letters",30,"letters",{"id":119,"doc_module":22,"doc_module_name":25,"category_name":120,"show_sort_weight":121,"slug":122},21,"Paper Templates",5,"papers-templates",{"id":124,"doc_module":22,"doc_module_name":25,"category_name":125,"show_sort_weight":4,"slug":126},158,"General","general-158",{"code":4,"msg":82,"data":128},{"doc_id":79,"user_id":129,"nickname":42,"user_avatar":130,"doc_module":22,"category_id":85,"category_name":29,"doc_title":10,"doc_description":12,"doc_content":131,"file_id":132,"file_url":133,"file_type":134,"file_size":135,"view_count":55,"is_deleted":4,"is_public":22,"is_downloadable":22,"audit_status":22,"page_count":30,"language":136,"language_code":8,"site_id":7,"html_lang":8,"table_of_contents":137,"faqs":138,"seo_title":139,"seo_description":12,"update_tm":140,"read_time":22},2336475104957,"https://ap-avatar.wpscdn.com/avatar/22000c4c6bd8a5076e1?x-image-process=image/resize,m_fixed,w_180,h_180&k=1787554080175789136","CSCE 156 – Lab 07: SQL I  \nHandout  \n0. Prior to the Laboratory  \n1. Review the laboratory handout.  \n2. Create a MySQL account and change the account password using the following directions at:  \n[http://www.cse.unl.edu/grad/resources/faq_details.php?category=CSCE_Resources\\#Mysqldata](http://www.cse.unl.edu/grad/resources/faq_details.php?category=CSCE_Resources#Mysqldata)baseAccount  \n3. Review the supplemental SQL Cheat Sheet for the Album Database  \n4. Review the following materials:  \n\n| Topic | Link |\n| --- | --- |\n| Information About Databases and Tables | \u003Cbr>[http://dev.mysql.com/doc/refman/5.6/en/getting](http://dev.mysql.com/doc/refman/5.6/en/getting)information. html |\n| Connecting to MySQL from the command line | [http://dev.mysql.com/doc/refman/5.6/en/connecting](http://dev.mysql.com/doc/refman/5.6/en/connecting)disconnecting.html |\n| Retrieving data | [http://www.w3schools.com/sql/sql_select.asp](http://www.w3schools.com/sql/sql_select.asp) |\n| Conditional clause | [http://www.w3schools.com/sql/sql_where.asp](http://www.w3schools.com/sql/sql_where.asp) |\n| Inserting data | [http://www.w3schools.com/sql/sql_insert.asp](http://www.w3schools.com/sql/sql_insert.asp) |\n| Deleting data | [http://www.w3schools.com/sql/sql_delete.asp](http://www.w3schools.com/sql/sql_delete.asp) |\n| Updating data | [http://www.w3schools.com/sql/sql_update.asp](http://www.w3schools.com/sql/sql_update.asp) |\n\nSome functions  \ncount()  [http://www.w3schools.com/sql/sql_func_count.asp](http://www.w3schools.com/sql/sql_func_count.asp)  \nmin()  [http://www.w3schools.com/sql/sql_func_min.asp](http://www.w3schools.com/sql/sql_func_min.asp)  \n\n| Joining tables | inner join | [http://www.w3schools.com/sql/sql_join_inner.asp](http://www.w3schools.com/sql/sql_join_inner.asp)  |\n| --- | --- | --- |\n|  | left join | [http://www.w3schools.com/sql/sql_join_left.asp](http://www.w3schools.com/sql/sql_join_left.asp) |\n|  | right join | \u003Cbr>_ _\u003Cbr>[http://www.w3schools.com/sql/sql](http://www.w3schools.com/sql/sql) join right.asp |\n\n1. Lab Objectives & Topics  \nUpon completion of this lab you should be able to:  \n􀁸 Connect to a database and execute queries  \n􀁸 Perform basic Create, retrieve, update, and delete (CRUD) operations  \n􀁸 Understand more complex queries using Joins and Aggregate functions  \n2. Problem Statement  \nYou will be connecting to the remote MySQL server on CSE and executing through the command line interface. The queries you will be performing involve a database that contains data about various music albums and the artists involved. The database structure is illustrated in the ER (Entity-Relation) diagram in Figure 1.  \nFigure 1: The Albums Database  \nImporting the Database  \nYou will need to “install” the Albums database and data into your own database on CSE. Note: database in this sense is just a collection of related tables; on CSE you only have access to one actual database—the database named after your CSE login. To import the Albums database, take the following steps.  \nInstructions  \n1. Download the Albums.sql file (a DDL file—Data Description Language) from Blackboard to your Z drive  \n2. Review the contents of this file but do not change it  \n3. Connect to CSE through PuTTY  \n4. From the directory containing the Albums.sql file, execute the following:  \nmysql –u username –p username \u003C Albums .sql  \nwhere username is replaced with your CSE login; enter your MySQL password. This redirects the  \ncontents of the Albums.sql file (a collection of SQL commands) to the mysql command line  \ninterface, creating all the tables and inserting all the data necessary.  \n5. Start the mysql command line interface:  \nmysql –u username –p username  \n6. From the command line, you can now execute basic SQL queries. To verify that the database was installed correctly, execute:  \nSHOW TABLES;  \nThe six Album-related tables should be listed. You can view the structure of a table by using: DESCRIBE TableName  \n7. Complete the worksheet and have a lab i","cbCaisnhw31imGl4","https://ap.wps.com/l/cbCaisnhw31imGl4","pdf",582844,"English","# Prior to the Laboratory\n# Lab Objectives & Topics\n# Problem Statement\n# Importing the Database\n## Instructions\n# MySQL Workbench\n# SQL Supplemental Cheat Sheet","[{\"question\":\"How do you import the Albums database into the CSE MySQL environment?\",\"answer\":\"Download Albums.sql, do not modify it, connect through PuTTY, then run the mysql command that redirects the Albums.sql contents into the mysql command line to create tables and insert data.\"},{\"question\":\"What commands confirm that the database was installed correctly and that tables exist?\",\"answer\":\"Use SHOW TABLES to list the six Albums-related tables, and use DESCRIBE TableName to view the structure of a specific table.\"},{\"question\":\"What is the alternative to using the command line client for running SQL queries?\",\"answer\":\"MySQL Workbench provides a GUI client where you launch the app, open a connection, enter host name and credentials, and then run queries from the interface.\"}]","CSCE 156 - Lab 07: SQL I - Handout | PDF",1791926148]