SQL has a lot of repetitive statements, and with the following SQL command list, you will be able to grab many common SQL operations to make your ability to grab data even quicker!
When adding any of the following SQL developer snippets to Pieces, developers will receive relevant tags for easy and fast search in Pieces, a description for context, and related links.
Tags: sql, select
Select
Use the select SQL command to select data from a table.
Related links:
Tags: sql, order by
Order By
Use the SQL order by command to sort the result-set in ascending or descending order.
Related links:
Tags: sql, select, distinct
Select distinct
The select distinct command in SQL is used to return only distinct values.
Related links:
Tags: sql, and
AND
This sample SQL code displays a record if all the conditions separated by AND are true.
Tags: sql, or
OR
The OR command in SQL displays a record if any of the conditions separated by OR is TRUE.
Tags: sql, not
NOT
This NOT SQL sample code snippet displays a record if the condition(s) is NOT TRUE.
Related links:
Tags: sql, insert into
Insert into
This SQL code snippet inserts new records into a table.
Tags: sql, update
Update
The Update command in SQL is used to modify the existing records in a table.
Tags: sql, delete
Delete
The Delete command in SQL is used to delete existing records in a table.
Tags: sql, count
Count
The Count command in SQL returns the number of rows that matches a specified criterion.
Tags: sql, average, avg
Avg
The Avg command in SQL returns the average value of a numeric column.
Tags: sql, sum
Sum
The Sum command in SQL returns the total sum of a numeric column.
Related links:
Tags: sql, like
Like
The Like command in SQL is used to search for a specified pattern in a column.
Related links:
Tags: sql, in
IN
The IN command in SQL allows you to specify multiple values in a WHERE clause.
Related links:
Tags: sql, inner join
Inner Join
The Inner Join Command in SQL selects records that have matching values in both tables.
Tags: sql, left join
Left Join
The Left Join command in SQL returns all records from the left table and the matching records from the right table. The result is no records from the right side if there is not a match.
Tags: sql, right join
Right Join
The right join command in SQL returns all records from the right table and the matching records from the left table. The result is no records from the left side if there is not a match.
Tags: sql, full join
Full Join
The Full Join SQL command returns all records when there is a match in left or right table records.
Related links:
Tags: sql, self join
Self Join
The Self Join SQL command is a regular join but the table is joined with itself.
Tags: sql, group by
Group By
The Group By command in SQL groups rows that have the same values into summary rows.
Related links:
Tags: sql, union
Union
The Union command in SQL is used to combine the result-set of two or more SELECT statements.
Tags: sql, having
Having
The Having command in SQL specifies conditions that filter which group results appear in the results.
Tags: sql, exists
Exists
The Exists Command in SQL tests for the existence of any record in a subquery.
Tags: sql, database, create
Create DB
Use the SQL create DB Command to create a new SQL database.
Related links:
Tags: sql, table, create
Create table
Use this SQL snippet to create a new table.