SELECT Statement with WHERE Clause
If we want to see the values in table with the specific conditions then we will use WHERE Clause with SELECT statement.
Query:
SELECT * FROM employees WHERE department_id = 2;
This retrieves all the columns from the “employees” table where the department ID is 2.
Output:
SELECT Statement in MariaDB
MariaDB uses SQL (Structured Query Language) and it is an open-source relational database management system (RDBMS) for managing and manipulating data. The SELECT statement is the most basic of all the SQL statements. It is essential to get data out of one or more database tables and display it. In this article, we will examine the syntax of the SELECT statement in MariaDB to retrieve records from a table.