SQL Complete Reference Index
Select any item below to open its full syntax specification, parameters, and live example.
operator
!=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
ABSABS(x)
Absolute magnitude; the most negative fixed-width integer can overflow. Example target: PostgreSQL 17. No tables or extensions required.
AGEAGE(end_timestamp,start_timestamp)
Computes a symbolic interval using calendar years and months rather than only elapsed seconds. Example target: PostgreSQL 17. No tables or extensions required.
transaction
admin
ALTER DATABASEALTER DATABASE bm_lab_db SET statement_timeout = '5s';
Sets a database-specific default for future sessions, subject to parameter permissions and role overrides.
ALTER EXTENSIONALTER EXTENSION hstore SET SCHEMA bm_lab;
Moves extension objects to a schema when the extension is relocatable and privileges permit.
statement
materialized-view
Showing 20 of 544 entries