Results for “require”
Small, practical examples. Search by task or narrow things down below.
Treat an empty trimmed value as missing
SQLite: NULLIF converts an empty string to NULL before a fallback is applied.
SQLite✓ Tested
Trim and discard blank lines
TypeScript: Split a text block, trim each line, and keep nonempty values.
TypeScript✓ Tested
Trim surrounding whitespace
Remove leading and trailing JavaScript string whitespace.
JavaScript✓ Tested
Trim whitespace around a string
PowerShell: The Trim method removes surrounding whitespace while preserving the middle of the string.
PowerShell✓ Tested
Turn a condition into a result label
SQL Server: Use CASE to describe stock availability for each row.
SQL Server✓ Tested
Turn a condition into a result label
Postgres: Use CASE to describe stock availability for each row.
Postgres✓ Tested
Turn a condition into a result label
SQLite: Use CASE to describe stock availability for each row.
SQLite✓ Tested
Turn JSON into typed rows
Project JSON array items into SQL columns.
OPENJSON✓ Tested
Turn known group values into columns
SQL Server: Conditional aggregation gives a portable pivot when the category set is known.
SQL Server✓ Tested
Turn known group values into columns
Postgres: Conditional aggregation gives a portable pivot when the category set is known.
Postgres✓ Tested
Turn known group values into columns
SQLite: Conditional aggregation gives a portable pivot when the category set is known.
SQLite✓ Tested
Type a dictionary with Record
Limit a lookup table to a known set of keys.
Record✓ Tested