mirror of
https://github.com/treffynnon/sqlstyle.guide.git
synced 2025-03-09 12:49:51 -05:00
More typos
This commit is contained in:
parent
25d592af26
commit
dd6424c431
1 changed files with 3 additions and 3 deletions
|
@ -102,9 +102,9 @@ SELECT first_name
|
||||||
### Aliasing or correlations
|
### Aliasing or correlations
|
||||||
|
|
||||||
* Should relate in some way to the object or expression they are aliasing.
|
* Should relate in some way to the object or expression they are aliasing.
|
||||||
* As rule of thumb the correlation name should be the first letter of each word
|
* As a rule of thumb the correlation name should be the first letter of each word
|
||||||
in the object's name.
|
in the object's name.
|
||||||
* If there is already a correlation with same name then append a number.
|
* If there is already a correlation with the same name then append a number.
|
||||||
* Always include the `AS` keyword—makes it easier to read as it is explicit.
|
* Always include the `AS` keyword—makes it easier to read as it is explicit.
|
||||||
* For computed data (`SUM()` or `AVG()`) use the name you would give it were it
|
* For computed data (`SUM()` or `AVG()`) use the name you would give it were it
|
||||||
a column defined in the schema.
|
a column defined in the schema.
|
||||||
|
@ -371,7 +371,7 @@ constraints along with field value validation.
|
||||||
* Use alphabetical order where `ON DELETE` comes before `ON UPDATE`.
|
* Use alphabetical order where `ON DELETE` comes before `ON UPDATE`.
|
||||||
* If it make senses to do so align each aspect of the query on the same character
|
* If it make senses to do so align each aspect of the query on the same character
|
||||||
position. For example all `NOT NULL` definitions could start at the same
|
position. For example all `NOT NULL` definitions could start at the same
|
||||||
character position. This is not hard and fat, but it certainly makes the code
|
character position. This is not hard and fast, but it certainly makes the code
|
||||||
much easier to scan and read.
|
much easier to scan and read.
|
||||||
|
|
||||||
##### Validation
|
##### Validation
|
||||||
|
|
Loading…
Reference in a new issue