Which one do you prefer to store text in your database? The original casing of the data, or some kind of normalization. Also, should I enforce this with triggers? or should I preprocess input data with client code?
I ask you, because I'm not sure about if there is any difference, besides additional processing time to display data (capitalization of names, for example).
All Caps SQL Commands Show example queries with ALL CAPS, First Letter Caps, and lowercase SQL commands. For readability, all SQL commands should be written in uppercase letters. This allows the reader to identify the keywords in the SQL statement and easily determine what the query is executing.
It is legal to write commands in lowercase, but this often leads to subtle bugs with lowercase attribute/column names, so we expect you to use the ALLCAPS convention for any commands or datatypes. Database names (e.g. c9 or imdb ) should be lowercased (no numbers or special characters lie "_" or "-").
No, the SQL language is not case-sensitive. Any SQL command text can mixed uppercase and lowercase letters.
It is thought by cognitive scientists and typographers alike, that lower-case text is more legible than upper-case. Yet lower-case letters are, on average, smaller in height and width than upper-case characters, which suggests an upper-case advantage.
Store in original case, unless there is a reason to do otherwise. The time spent to upper or lower case the data is likely very small, and you never know when you'll want the real, original data back in the future.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With