SQL Snippets
Reusable SQL patterns for paging, duplicates, pivots, and date ranges across SQL Server and MySQL.
Continue ReadingReusable SQL patterns for paging, duplicates, pivots, and date ranges across SQL Server and MySQL.
Continue ReadingDuplicate a SQL Server database with BACKUP/RESTORE, DBCC CLONEDATABASE, or scripting for dev/test copies.
Continue ReadingFormat dates in SQL Server with CONVERT, FORMAT, and style codes for locale-safe display and reporting.
Continue ReadingTrim the final character from strings in SQL Server with LEFT, SUBSTRING, and LEN for trailing delimiters.
Continue ReadingSplit CSV strings into rows for SQL IN filters using STRING_SPLIT, table-valued functions, or XML tricks.
Continue ReadingHandy SQL*Plus commands for scripting, formatting output, and running reports from the Oracle command line.
Continue ReadingUnderstand INNER, LEFT, RIGHT, and FULL joins in SQL with clear examples for relational queries.
Continue Reading