When working in SQL Server Management Studio (SSMS), editing multiple lines of code manually can get tedious — especially when making similar changes to multiple rows. Luckily, SSMS supports multi-line editing, and there’s a simple shortcut that can save you tons of time:
👉 Shift + Alt + Down Arrow
This powerful shortcut allows you to edit or insert text across multiple lines at once, just like column mode editing in other editors.
✅ When to Use This Shortcut
Let’s say you’re writing multiple UPDATE statements or duplicating similar code blocks like this:
UPDATE Employees SET Salary = 50000 WHERE EmployeeID = 1;
UPDATE Employees SET Salary = 52000 WHERE EmployeeID = 2;
UPDATE Employees SET Salary = 53000 WHERE EmployeeID = 3;
Now you realize you want to change the table name from Employees to Contractors in all lines.
Instead of editing each line individually, just:
🛠️ How to Use Shift + Alt + Down Arrow in SSMS
- Place your cursor right before the word
Employees(or after) in the first line. - Hold down Shift + Alt, then press the Down Arrow key to extend a vertical cursor across the lines you want to edit.
- Type
Contractors(or whatever change you want). - The change will be applied to all lines simultaneously.
You can also use Backspace or Delete to remove repeated content across multiple lines — perfect for batch editing SQL scripts.
🎯 Bonus: Works for Insert, Delete, and Commenting Too
This technique isn’t limited to just UPDATE statements. You can use multi-line editing for:
- Inserting column aliases
- Deleting repeated prefixes
- Commenting out multiple lines (
--) - Editing
INSERT,SELECT, orDELETEblocks
🧠 Final Thoughts
Shift + Alt + Down Arrow in SSMS is a simple but powerful shortcut that can boost your SQL productivity. Whether you’re refactoring scripts or batch editing values, this technique will help you work faster and cleaner.
💻 Try it out in your next SQL session — you might never go back to single-line editing again!



