How can I remove the extra spaces in Microsoft SQL Server 2022 desktop in the results grid?

Copper Contributor

 

There is a massive space between columns in the results tab, I had to reduce the zoom to 50% to get two columns in the screen at once. Please help me in eliminating this space.

 

RakhalM_0-1685727309945.png

 

3 Replies

@RakhalM 

 

Try using "Results to Grid" instead of what you have now, which is "Results to Text".

 

LainRobertson_0-1685731343607.png

 

If you prefer that format, you can then set it as the default format for future queries from under the Tools | Options menu item, under Query Results:

 

LainRobertson_1-1685731655681.png

 

 

Cheers,

Lain

@RakhalM that's not "results grid", it's the "Result to text" output and that's how it looks like; like a fix width CSV.

Change it to "Result to Grid", see SSMS Query Editor - SQL Server Management Studio (SSMS) | Microsoft Learn => "Result to ..." section.

@RakhaIM
Under the Query window, You need to right-click on the query and select "Result to Grid" as you may have an option "result to text" selected.