From 42e5491ea15d4dc01b8a58be4a62807058444f15 Mon Sep 17 00:00:00 2001 From: Konstantin Taranov Date: Mon, 10 Dec 2018 20:38:16 +0300 Subject: [PATCH] Add avoid using INSERT INTO with ORDER BY and shorthand with date/time operations --- SQL Server Name Convention and T-SQL Programming Style.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/SQL Server Name Convention and T-SQL Programming Style.md b/SQL Server Name Convention and T-SQL Programming Style.md index 26b1e24..e37d39f 100644 --- a/SQL Server Name Convention and T-SQL Programming Style.md +++ b/SQL Server Name Convention and T-SQL Programming Style.md @@ -123,6 +123,8 @@ SQL Server TSQL Coding Conventions, Best Practices, and Programming Guidelines END ``` More details [here](https://www.red-gate.com/hub/product-learning/sql-prompt/sql-prompt-code-analysis-avoid-using-isnumeric-function-e1029) + - Avoid using `INSERT INTO` a permanent table with `ORDER BY`, more details [here](https://www.red-gate.com/hub/product-learning/sql-prompt/sql-prompt-code-analysis-insert-permanent-table-order-pe020) + - Avoid using shorthand (`wk, yyyy, d` etc.) with date/time operations, use full names: `month, day, year`. More details [here](https://sqlblog.org/2011/09/20/bad-habits-to-kick-using-shorthand-with-date-time-operations) Example: