0
0
SQLquery~10 mins

Tables, rows, and columns concept in SQL - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to select all columns from the table named 'employees'.

SQL
SELECT [1] FROM employees;
Drag options to blanks, or click blank then click option'
Acolumns
B*
CALL
Drows
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'ALL' instead of '*'
Writing 'columns' which is not valid SQL syntax
2fill in blank
medium

Complete the code to select only the 'name' column from the 'students' table.

SQL
SELECT [1] FROM students;
Drag options to blanks, or click blank then click option'
Aname
Ball
Cnames
Dstudent_name
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'names' which is plural and may not exist
Using 'student_name' which is a different column
3fill in blank
hard

Fix the error in the code to select the 'age' column from the 'persons' table.

SQL
SELECT [1] FROM persons;
Drag options to blanks, or click blank then click option'
Aages
BAge
Cage
Dperson_age
Attempts:
3 left
💡 Hint
Common Mistakes
Using plural form 'ages'
Using a different column name like 'person_age'
4fill in blank
hard

Fill both blanks to select the 'id' and 'email' columns from the 'contacts' table.

SQL
SELECT [1], [2] FROM contacts;
Drag options to blanks, or click blank then click option'
Aid
Bemail
Cname
Dphone
Attempts:
3 left
💡 Hint
Common Mistakes
Using columns not in the table like 'name' or 'phone'
Forgetting the comma between column names
5fill in blank
hard

Fill all three blanks to select 'first_name', 'last_name', and 'age' columns from the 'users' table.

SQL
SELECT [1], [2], [3] FROM users;
Drag options to blanks, or click blank then click option'
Afirst_name
Blast_name
Cage
Demail
Attempts:
3 left
💡 Hint
Common Mistakes
Including columns not asked for like 'email'
Missing commas between column names