SOLVED

Outlining not working in SSMS 18.x and 19.x

Brass Contributor

Edit, This problem is also present in SSMS 20.1, Does Microsoft care at all, or are they not capable of fixing this?

 

In SSMS 18.x and 19.x, the outlining feature that allows you to collapse SQL code often stops working, i.e. the +/- next to the code disappears and neither shortcuts or clicking in the menu will collapse code.

I have tried to uncheck outline statements in the option under intellisense and then recheck it, but that makes no difference.

Closing SSMS and restarting sometimes helps, but after a while I'm back to the same problem.

I have never had this issue in SSMS 17.x

 

Does anyone else have this problem, and how do you solve it?

 

10 Replies
I'm having this problem as well, in version 18.10 (15.0.18390.0), with SQLPrompt installed. Reopening SSMS doesn't help. Occasionally, one level of outlining will appear at the start of a stored proc script. Once the outlining submenu disappeared from the Edit menu.

I've tried altering most of the settings associated with outlining, but nothing has helped.

This is a very useful feature, and I'd really like to be able to use it.
When the problem appears even simple queries like this won't collapse:
SELECT
*
FROM
sys.objects

Hi @MartinxN 

This questions was originally asked on ‎15-09-2021 about 2 years ago. Are you saying that you work on the same issue for 2 years?!?

 

You probably know what Dog Years means. In general each year for a dog is like 7 years for Human. This questions is more that one Computer years and each computer year is like 10000 years for Human as the tech change each minute. From the time you asked the question SSMS 18.x became obsolete. Therefore, the sirt step you should do, is to install the latest version of SSMS.

 

Please upgrade to the latest version and confirm if the issue continue. If it was a known bug then it was probably fixed

 

If the issue continue on the latest version of SSMS then w will dive into it more :smile:

best response confirmed by MartinxN (Brass Contributor)
Solution
Sorry for not updating the original text, this issue is also present in SSMS 19, in fact everything newer than SSMS 17 has this problem
I had the same problem for several months and also have been using SQL Prompt. In my case, I remembered that I'd disabled Intellisense, and so I tried toggling that back on. Outlining came back instantly.
Unfortunately that is not my experience, Intellisense have been turned on from the start and turning it off an on again does not help
This is still broken... 20,000 years later :face_with_rolling_eyes:
Make sure the setting is enabled...go to Tools > Options > Text Editor > Transact-SQL > IntelliSense, ensure that Outline statements is enabled.

@erinstellato if you read my description carefully, you will notice this part:

"I have tried to uncheck outline statements in the option under intellisense and then recheck it, but that makes no difference."

 

the point being that I cannot enable it when it stops working, other than closing and restarting SSMS a couple of times until it starts working again, which is very annoying to have to do since it is very slow to close and to start

Ah, my mistake, I misread it as the Intelliense option. I have this enabled for my local SSMS (version 19 and 20 installed) and have not seen the issue. Do you have any third party extensions installed? I noticed other folks mentioned RedGate Prompt but I am not sure if you have that extension, or any other one installed. Thanks.
1 best response

Accepted Solutions
best response confirmed by MartinxN (Brass Contributor)
Solution
Sorry for not updating the original text, this issue is also present in SSMS 19, in fact everything newer than SSMS 17 has this problem

View solution in original post