Closed librarianlise closed 3 years ago
Doh! @librarianlise this was something I was hoping we would add but dropped off somehow, a section on good style https://365datascience.com/sql-best-practices/ I thought we had included it but guess not! I can see a short episode after "Selecting and sorting data" or after/before "Database design"?
@libcce, I like the idea of framing it that way, as good style or best practices in a separate episode. I think it would work well after Selecting and sorting, and then maybe we could incorporate commenting from episode 5 into that new episode (if, as I suggest in another issue https://github.com/LibraryCarpentry/lc-sql/issues/100, we take the content from section 5 and put it elsewhere).
What would we think as a sub-lesson, or would you think 'best-practices' is its own episode? In your 'order of operations,' would you consider best practices as a late episode in the sql curriculum or earlier? I could see a case (haha) for either option...
@jyssy I can see a case for both too 😄 I'm leaning more towards a separate lesson though, something that is maybe optional. If it is optional then we have to include information in the instructor notes.
I'd be on board with making it a module just before/after db design. @librarianlise I'm assigning this to myself for today, but we can share it, just message me on slack!
simply that good readable style encourages the CAPs for SQL statements but don't count on case insensitivity because the interpreter does not case sensitivity. Maybe suggest a format: if you pick a capitalization schema, stick with it, CamelCase or something of the like @jyssy
Closing with PR on #129
We talk about SQL keywords/commands being case-insensitive ("We have capitalised the words SELECT and FROM because they are SQL keywords. This makes no difference to the SQL interpreter as it is case-insensitive, but it helps for readability and is therefore considered good style.") but we don't specify that tables/columns are case-sensitive - could add in. (Actually I'm just reading now that sometimes the tables/columns are not case-sensitive, it depends on the software/server settings. Look into further and decide whether it's useful info to include?)