SQL Complete Reference Index

Select any item below to open its full syntax specification, parameters, and live example.

SQL Tutorial

operator

13 entries
!=a != b
Alternative inequality spelling; prefer <> for standard-oriented examples. Ordinary comparisons with NULL produce unknown. Example target: PostgreSQL 17 and SQLite (local fixture tested).
%left % right
Returns the remainder for integer operands in PostgreSQL and SQLite. This example avoids dialect differences in noninteger operands. Example target: SQLite 3.46.1. Use only the isolated starter dataset; setup and expected results are in the batch evidence.
*left * right
Multiplies numeric operands. This arithmetic operator is different from the wildcard in SELECT *. Example target: SQLite 3.46.1. Use only the isolated starter dataset; setup and expected results are in the batch evidence.
+left + right
Adds numeric operands; NULL propagates and result types depend on operand types. Example target: SQLite 3.46.1. Use only the isolated starter dataset; setup and expected results are in the batch evidence.
-left - right
Subtracts the right numeric operand from the left; unary minus is a separate form. Example target: SQLite 3.46.1. Use only the isolated starter dataset; setup and expected results are in the batch evidence.
/left / right
Divides numeric operands. PostgreSQL and SQLite truncate integer division toward zero; division by zero differs between engines. Example target: SQLite 3.46.1. Use only the isolated starter dataset; setup and expected results are in the batch evidence.
<a < b
Tests strict less-than. Ordinary comparisons with NULL produce unknown. Example target: PostgreSQL 17 and SQLite (local fixture tested).
<=a <= b
Tests less-than or equality. Ordinary comparisons with NULL produce unknown. Example target: PostgreSQL 17 and SQLite (local fixture tested).
<>a <> b
Tests inequality using the conventional SQL spelling. Ordinary comparisons with NULL produce unknown. Example target: PostgreSQL 17 and SQLite (local fixture tested).
=a = b
Tests equality. Ordinary comparisons with NULL produce unknown. Example target: PostgreSQL 17 and SQLite (local fixture tested).
>a > b
Tests strict greater-than. Ordinary comparisons with NULL produce unknown. Example target: PostgreSQL 17 and SQLite (local fixture tested).
>=a >= b
Tests greater-than or equality. Ordinary comparisons with NULL produce unknown. Example target: PostgreSQL 17 and SQLite (local fixture tested).
ALLexpression operator ALL (subquery)
True if every comparison is true, including an empty subquery; false if any is false, otherwise NULL if any is unknown. Example target: PostgreSQL 17. Use only the isolated starter dataset; setup and expected results are in the batch evidence.

scalar

2 entries

transaction

1 entry

admin

2 entries

statement

1 entry

materialized-view

1 entry

Showing 20 of 544 entries

SQL Reference & Cheat Sheet | ByteMind