Few days ago, I received code which is very similar to code shown below.
select *
from Sales.SalesOrderDetail
where ProductID > 777
I am not the guy who go crazy for formatting but I do appreciate proper coding. I like if the code was formatted like below.
SELECT *
FROM Sales.SalesOrderDetail
WHERE ProductID > 777
The fastest way one can do this in SSMS is either search and replace or using SSMS short cut to covert keywords to upper case.
What I do is I select the word and hit CTRL+SHIFT+U and it SSMS immediately changes the case of the selected word. Similar way if one want to convert cases to lower case, another short cut CTRL+SHIFT+L is also available.
Reference: Pinal Dave (https://blog.sqlauthority.com)
37 Comments. Leave new
The problem with CTRL-SHIFT-U is that it takes two hands. I would rather not have to drop the mouse to uppercase something.
Hi,
You are not just concentrating on queries but also concentrates on small things like this. Continue your great work. You have saved my time
CTRL+SHIFT+L didn’t worked for me
how to perform my query window all blue font convert uppercase to lowercase an lowercase to uppercase
I always forget this shortcut. Thank you for remembering me Sir!
Thanks!
Great shortcut! Thanks!
Ctrl+U will change it to lower case
CTRL+ SHFT+ U will change it to uppar case
Ctrl+U will not do anything… Ctrl+Shift+L works for lowercasing
Thanks for this INFO.