You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CLAUDE.md
+6-1Lines changed: 6 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,15 +2,20 @@
2
2
3
3
This document outlines the T-SQL coding style preferences for Erik Darling (Darling Data, LLC) and must be strictly followed when writing or modifying SQL code.
4
4
5
+
## Project Constraints
6
+
7
+
-**No Additional Dependencies**: Do not create helper functions, procedures, views, or any other database objects as dependencies for stored procedures. All logic must be self-contained within the procedure itself to avoid deployment and dependency management complexity.
8
+
5
9
## General Formatting
6
10
7
11
-**Keywords**: All SQL keywords in UPPERCASE (SELECT, FROM, WHERE, JOIN, etc.)
8
12
-**Functions**: All SQL functions in UPPERCASE (CONVERT, ISNULL, OBJECT_ID, etc.)
9
-
-**Data types**:
13
+
-**Data types**:
10
14
- Never abbreviate data types (use INTEGER instead of INT)
11
15
- All data types must be lowercase (varchar, nvarchar, datetime2, bigint, etc.)
12
16
- Length specifications must also be lowercase: nvarchar(max), not nvarchar(MAX)
13
17
- Precision and scale specifications must be lowercase: decimal(38,2), not DECIMAL(38,2)
18
+
- Always use sysname for SQL Server object names (database names, table names, schema names, column names, index names, etc.) rather than nvarchar(128)
14
19
-**Keywords**: Never abbreviate keywords (use EXECUTE instead of EXEC, TRANSACTION instead of TRAN, PROCEDURE instead of PROC)
15
20
-**Indentation**: 4 spaces for each level of indentation (NEVER use tabs)
The DBCC FREESYSTEMCACHE command used in these scripts will clear the security cache, which may cause a temporary performance impact as the cache is rebuilt. Test thoroughly in non-production environments before deploying to production.
Copy file name to clipboardExpand all lines: Helper Views/README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -100,5 +100,5 @@ EXECUTE dbo.tempdb_tester;
100
100
101
101
Some of these scripts (particularly WhatsUpMemory) may cause performance issues if run on busy production servers. Use with caution, especially on servers with large amounts of memory.
0 commit comments