MySQL SELECT

Written by Impact Atlas
Updated 1 year ago

The SELECT statement is used to select data from a database. The data returned is stored in a result table, called the result-set.

SELECT Syntax
SELECT column1, column2, ...
FROM table_name;

Here, column1, column2, ... are the field names of the table you want to select data from. If you want to select all the fields available in the table, use the following syntax:

SELECT * FROM table_name;

EXAMPLE:

The following SQL statement selects the "8_Participant First Name", "9_Participant Last Name", "13_Age", "36_Marital Status" columns from the "registration" table. 

IMPORTANT NOTE:
1. The column names used in the SELECT query need to be encapsulated in backticks `` and exactly match the name from the table.

After you create or modify the query, you need to execute the query by clicking the run button. This will ensure that the query is written correctly and without errors and it will also display the data results below the console.

The final step is to save the question under any given name and add it to any dashboard. 

Did this answer your question?