From the course: MySQL Essential Training
Unlock this course with a free trial
Join today to access over 24,800 courses taught by industry experts.
Selecting rows - MySQL Tutorial
From the course: MySQL Essential Training
Selecting rows
- [Instructor] Hi, I'm Bill Weinman. The SELECT statement is used for most data retrieval in SQL. For this lesson, we'll use the world database, and here in MySQL Workbench, I'm connected with my admin connection, and I'll simply type USE world and execute it. And that opens the world database for our use. Let's start with a simple SELECT statement. If I type SELECT 'Hello, World' and I have Hello, World in single quote marks, and I have terminated my statement with a semicolon, when I execute it, you notice that the result comes up and it gives us this one column in our result. The column is titled Hello, World and the result is Hello, World. So the SELECT statement is used for queries that will return a value or a set of values. SELECT is used to display the result of any query. In this case, the query is a literal string. It's still a query, it just doesn't come from the database. You could just as easily say SELECT 1 + 2, execute that. And I have a result with one column. The…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
A brief overview of SQL4m 28s
-
(Locked)
Database organization2m 51s
-
(Locked)
Selecting rows5m 47s
-
(Locked)
Selecting columns2m 21s
-
(Locked)
Counting rows3m 5s
-
(Locked)
Inserting data3m 26s
-
(Locked)
Updating data4m 12s
-
(Locked)
Deleting data4m 10s
-
(Locked)
Joining queries across tables3m 57s
-
(Locked)
Finding databases, tables, and columns1m 24s
-
-
-
-
-
-
-