Expressions can produce values without changing stored data. A function is a named operation; UPPER transforms text and ROUND rounds a number. An alias labels the resulting column.
SELECT title, UPPER(title) AS display_title,
CASE WHEN pages IS NULL THEN 'unknown'
WHEN pages >= 100 THEN 'long'
ELSE 'short' END AS size
FROM books ORDER BY id;
Moss Atlas and Clay Roads are long, River Notes is short, and Night Sky is unknown. CASE checks conditions in order and returns the first matching result. SQLite also offers IIF, but CASE is more widely portable. Functions and text case handling can vary by dialect. SQLite can evaluate expressions without a table:
SELECT ROUND(13.75, 1) AS rounded;
The result is 13.8. Rounding displayed numbers does not change the stored data.