Write coding standards for SQL #118
Labels
No labels
_CRITICAL_
API
app
backEnd
Blocked, waiting for further changes
bug
cleanup
close
design
duplicate
enhancement
feature request
frontEnd
help wanted
invalid
low priority
needs input
needs review
project documentation
question
research
reviewed
script
security
SQL
style
testing
topLevel
wontfix
No milestone
No project
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Andras/BoundlessFlowCampus2K#118
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Parent issue: #8
If coding conventions for a specific part is not documented here, please refer to /SQL style standard
Naming Conventions
General
Tables
Columns
Table creation
CREATE TABLE staff (PRIMARY KEY (staff_num),staff_num INT(5) NOT NULL,first_name VARCHAR(100) NOT NULL,pens_in_drawer INT(2) NOT NULL,CONSTRAINT pens_in_drawer_rangeCHECK(pens_in_drawer BETWEEN 1 AND 99));Stored procedures
Universal suffixes
Query syntax
SELECT species_name, AVG(height) AS average_heightFROM floraWHERE species_name = 'Banksia'OR species_name = 'Sheoak'OR species_name = 'Wattle'GROUP BY species_name, observation_dateReviewed and added to the Wiki.