Aan de slagGa gratis aan de slag

Where

You won't usually want to retrieve every row in your database. You'll have specific information you need in order to answer questions from your boss or colleagues.

The WHERE clause is essential for selecting, updating (and deleting!) data from your tables. You'll continue working with the grid dataset for this exercise.

Deze oefening maakt deel uit van de cursus

Introduction to SQL Server

Cursus bekijken

Oefeninstructies

  • Select the description and event_year columns.
  • Return rows WHERE the description is 'Vandalism'.

Praktische interactieve oefening

Probeer deze oefening eens door deze voorbeeldcode in te vullen.

-- Select description and event_year
SELECT 
  ___, 
  ___ 
FROM 
  grid 
  -- Filter the results
___ 
  ___ = '___';
Code bewerken en uitvoeren