Results for “table variable”
Small, practical examples. Search by task or narrow things down below.
Delete only a named scratch file
PowerShell: Use LiteralPath and avoid recursive removal for a single known file.
PowerShell✓ Tested
Discard incidental output from a setup command
PowerShell: Out-Null prevents setup objects from becoming part of a function or script’s useful result.
PowerShell✓ Tested
Dispatch values with wildcard patterns
PowerShell: Switch -Wildcard interprets shell-style matching patterns for each clause.
PowerShell✓ Tested
Display a fallback for missing data
SQL: Return a supplied label when a column contains NULL.
SQL✓ Tested
Distinguish a file from a directory
PowerShell: Test-Path can constrain the kind of item that is accepted.
PowerShell✓ Tested
Distinguish row count from non-null value count
SQL: COUNT(*) includes every row while COUNT(column) skips NULL values.
SQL✓ Tested
Divide an ordered result into numbered buckets
SQL: NTILE distributes rows across buckets; include a unique tie-breaker for deterministic assignment.
SQL✓ Tested
Enable and use foreign keys
Turn on relationship enforcement for the connection.
foreign keys✓ Tested
Encode and decode UTF-8 text with Base64
PowerShell: Convert the string to bytes explicitly before Base64 encoding.
PowerShell✓ Tested
Enforce a bounded numeric range
SQL: A named CHECK constraint keeps numeric values inside an inclusive interval.
SQL✓ Tested
Enforce a numeric range at a function boundary
PowerShell: ValidateRange performs argument validation before work begins.
PowerShell✓ Tested
Enforce a relationship between two columns
SQL: A row-level CHECK can require a start value to be no greater than an end value.
SQL✓ Tested