← CodeClarityLab Home
Browse by Category
+ added · updated 7d
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
MySQL GROUP BY and Aggregates
GROUP BY collapses rows with matching column values into one — aggregate functions (COUNT, SUM, AVG, MAX, MIN) compute values per group.
2mo ago database intermediate
Diagram: MySQL Index Types MySQL Index Types
B-tree, FULLTEXT, SPATIAL, and HASH indexes — each optimised for different query patterns.
2mo ago database intermediate
MySQL JSON Column Type
A native JSON storage type introduced in MySQL 5.7 that validates, indexes, and queries JSON documents with dedicated functions.
2mo ago database intermediate
MySQL LIMIT and OFFSET Pagination
LIMIT restricts result row count; OFFSET skips rows for pagination — but OFFSET-based pagination degrades on large tables.
2mo ago database intermediate
MySQL Query Cache (Deprecated)
A server-side cache for SELECT results removed in MySQL 8.0 — it caused severe scalability issues under concurrent writes.
2mo ago database intermediate
MySQL Subqueries
A query nested inside another — useful for filtering and deriving values, but correlated subqueries re-execute per outer row and can be O(n²).
2mo ago database intermediate
Diagram: N+1 Query Problem N+1 Query Problem PHP 5.1+
A performance anti-pattern where fetching N records triggers N additional queries — one per record — instead of a single JOIN.
2mo ago database intermediate
Diagram: PDO Transactions PDO Transactions PHP 5.1+
PDO wraps multiple queries in an atomic unit — either all succeed or all roll back.
2mo ago php intermediate
PDO::ATTR_EMULATE_PREPARES PHP 5.1+
Controls whether PDO sends real prepared statements to the database or emulates them client-side in PHP.
CWE-89 OWASP A3:2021
2mo ago php intermediate
PDOStatement::bindParam() vs bindValue() PHP 5.1+
Two PDO methods for binding variables to placeholders — bindParam() binds by reference (evaluated at execute), bindValue() binds by value (evaluated immediately).
2mo ago php intermediate
PHP Generators PHP 5.5+
Functions using yield that produce values lazily — one at a time — instead of building a complete array in memory.
2mo ago php intermediate
Soft Delete Pattern
Marking records as deleted with a deleted_at timestamp instead of physically removing them — preserving data for auditing and recovery.
2mo ago database intermediate
SQL Window Functions
Window functions (ROW_NUMBER, RANK, LAG, LEAD, SUM OVER) perform calculations across a set of rows related to the current row without collapsing them into a single aggregate — enabling rankings, running totals, and comparisons within result sets.
2mo ago database intermediate
Structured Logging PHP 8.0+
Emitting log entries as machine-parseable key-value pairs (JSON) rather than free-form strings — enabling filtering, aggregation, and alerting.
2mo ago observability intermediate
Test Doubles PHP 8.0+
Substitute objects used in tests to replace real dependencies — mocks, stubs, spies, fakes, and dummies each serve a different purpose.
2mo ago testing intermediate
Trie (Prefix Tree)
A tree where each node represents a character — paths from root to leaf spell out keys, enabling O(m) lookup, prefix search, and autocomplete where m is key length, independent of dataset size.
2mo ago data_structures intermediate
Diagram: AI Guardrails AI Guardrails
Runtime constraints and safety filters applied around LLM calls to detect, block, or rewrite inputs and outputs that are harmful, off-topic, or policy-violating.
2mo ago ai_ml intermediate
Diagram: AI Observability AI Observability
The practice of monitoring, tracing, and evaluating LLM-powered systems in production — covering latency, token costs, prompt drift, output quality, and failure modes.
2mo ago ai_ml intermediate
Diagram: LLM Temperature & Sampling Strategies LLM Temperature & Sampling Strategies
Parameters that control the randomness and diversity of LLM output — temperature scales token probabilities, while top-p and top-k limit the candidate pool before sampling.
2mo ago ai_ml intermediate
Diagram: Multimodal AI Multimodal AI
AI models that process and generate across multiple input or output modalities — text, images, audio, and video — within a single unified architecture.
2mo ago ai_ml intermediate
✓ schema.org compliant