Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CTRL + K, CTRL + F (Format Code) Not Working in MS SQL Server

The format selection command isn't working in SQL server management studio 2008 for me and I'm wondering if anyone might know how to get it working. I don't know if it was ever working.

like image 713
John Avatar asked Sep 16 '11 14:09

John


2 Answers

Do you have any add-ins installed? For me Ctrl+K, Ctrl+F brings up the SSMS Tools Pack find dialog. So perhaps this is happening because an add-in has taken over the keyboard combo.

Also, what is your keyboard scheme under Tools > Options > Environment > Keyboard? If this has been switched to "SQL Server 2000" you might try switching it back to Standard.

Finally, I believe there are cases where the keyboard shortcuts can get messed up depending on the co-existence and order of install for Visual Studio / BIDS etc.

like image 60
Aaron Bertrand Avatar answered Oct 05 '22 00:10

Aaron Bertrand


IN SQL SERVER 2014

  • First do: Ctrl +K
  • Then: Ctrl+ Y
like image 34
Vladi Avatar answered Oct 05 '22 01:10

Vladi