
Master the select clause syntax, including choosing all or specific columns and the mandatory from clause from the table, as shown with 14 rows across 8 columns.
Learn to create a MySQL table by defining table name, columns, and data domains, and applying constraints such as primary key and auto increment, via command line or workbench.
Master the order by clause to sort query results in ascending or descending order. Apply it to single or multiple columns, using asc or desc for precise output.
Group by clause organizes records into value-based groups, then apply aggregate functions like count, sum, average, min, and max to compute department totals and salaries, including multi-column groupings.
Explore how the unique constraint prevents duplicate values in a column, supports multi-column constraints, and permits nulls, with hands-on examples on a student table.
Explore check constraints that validate column values with a condition, add constraints to tables, manage existing data, and respond to violations and automatic constraint naming.
Explore the default constraint in MySQL, which assigns a default value when a column is not specified, preventing nulls and guiding inserts through practical table creation and examples.
Learn how the auto_increment constraint automatically generates unique keys for new records, with primary key requirements, syntax, and hands-on examples of inserts and adjusting the maximum value.
Discover the if function in mysql, learn how it evaluates a condition and returns a value when true or false, and see practical syntax and examples.
Explore theta join and equi join in MySQL, using conditional predicates and the equal operator to join two tables, handle column ambiguity, and apply selective projections.
Develop practical skills to filter employees who died in the year 1993 using SQL, employing between date ranges and year-based formats to fetch matching records.
Master how to filter employees who joined in August 1998 using between date ranges, select all details, and extract the month to enable flexible month-based queries.
Course Description: This course provides a comprehensive introduction to the language of relational databases: Structured Query Language (SQL). Topics covered include: Entity-Relationship modeling, the Relational Model, the SQL language: data retrieval statements, data manipulation and data definition statements. All interactive reading problems involve the use of "live" SQL. Homework will be done using databases running in MySQL which students install on their machines. Students develop a real-world database project using MySQL during the course.
Prerequisites: This course is designed database developers or students who desire a basic to advance level of proficiency with the Structured Query Language (SQL). Prerequisite: Basic computer literacy including.
Justification: This course will provide a solid preparation in SQL in the Computer Science and Informatics majors who plan to take database or data science courses. A knowledge of this material is also an important skill for anyone planning to do software engineering and development. It is also a service course for students outside of the CS major who work with or plan to work with relational databases and data science such as students studying social science, business, biological and physical sciences, among others.
Course Objectives:
Learn structured query language (SQL) to an intermediate/advanced level.
Be able to write data retrieval queries and evaluate the result set.
Be able to write SQL statements that edit existing data.
Be able to write SQL statements that create database objects.
Understand the structure and design of relational databases.
Understand the importance and major issues of database security and the maintenance of data integrity.