This way you can select all students that are not found (by their id) in the grade table.
SELECT *
FROM student
WHERE id NOT IN (SELECT student_id FROM grade)
More Related Contents:
- Get the mentioned output by SQL query
- Decrease salary using a SQL query
- MySQL query finding values in a comma separated string
- Conditional WHERE clause in SQL Server
- Concatenate row values T-SQL
- MIN/MAX vs ORDER BY and LIMIT
- Difference between “read commited” and “repeatable read”
- Reference alias (calculated in SELECT) in WHERE clause
- Implement paging (skip / take) functionality with this query
- Copy data into another table
- When to use Common Table Expression (CTE)
- SQL server ignore case in a where expression
- Find closest date in SQL Server
- Get the distinct sum of a joined table column
- INSERT SELECT statement in Oracle 11G
- Alternate of lead lag function in SQL Server 2008
- How to split comma-separated values?
- SQL – Select first 10 rows only?
- SQL Oracle LEFT JOIN and SUBQUERY error: ORA-00905: missing keyword
- What is Full Text Search vs LIKE
- SQL – Inserting a row and returning primary key
- How do I start auto increment from a specific point?
- How to search SQL column containing JSON array
- How to use a dynamic parameter in a IN clause of a JPA named query?
- Perform regex (replace) in an SQL query
- How to create a new database with the hstore extension already installed?
- How important are lookup tables?
- Finding unmatched records with SQL
- Hierarchical Queries in SQL Server 2005
- how to use LIKE with column name