Request Cleaner Object Scripts from SSMS Object Explorer -> Right Click -> Script Object as - by gregory_may

Status : 

  Fixed<br /><br />
		This item has been fixed in the current or upcoming version of this product.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.


16
0
Sign in
to vote
ID 3139199 Comments
Status Closed Workarounds
Type Suggestion Repros 0
Opened 8/9/2017 9:25:00 AM
Access Restriction Public

Description

There is a good deal of extra text at the top of Object Scripts from SSMS Object Explorer -> Right Click -> "Script Object as".   
With SSMS 17.2 its much worse (Scripting Parameters were added).   
We often use SSMS to develop then check into TFS for builds.  
Please add options in to disable the text below in Tools -> Options -> Sql Server Object Explorer -> Scripting. 
The text below is an example of what we delete every time before editing or checking into TFS:

/*    ==Scripting Parameters==

    Source Server Version : SQL Server 2014 (12.0.5000)
    Source Database Engine Edition : Microsoft SQL Server Enterprise Edition
    Source Database Engine Type : Standalone SQL Server

    Target Server Version : SQL Server 2014
    Target Database Engine Edition : Microsoft SQL Server Standard Edition
    Target Database Engine Type : Standalone SQL Server
*/

SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
Sign in to post a comment.
Posted by VeritableHero on 10/11/2017 at 5:47 AM
Thank you Charles and any that worked on adding this option. It's a small thing but greatly appreciated.
Posted by David Rueter on 8/31/2017 at 11:29 AM
@Charles, where is this scripting option? In 14.0.17177.0 I can't find an option to disable the version information output as "Scripting Parameters". I still see the following in all SSMS scripts:

/*    ==Scripting Parameters==

    Source Server Version : SQL Server 2016 (13.0.4446)
    Source Database Engine Edition : Microsoft SQL Server Standard Edition
    Source Database Engine Type : Standalone SQL Server

    Target Server Version : SQL Server 2017
    Target Database Engine Edition : Microsoft SQL Server Standard Edition
    Target Database Engine Type : Standalone SQL Server
*/

(I do see where I can control other aspects of scripting.)

I ask because now this feedback item is marked as Closed.
Posted by Microsoft on 8/17/2017 at 11:03 AM
Hello all,

Thanks for the feedback. I will be adding a Scripting Option to disable this text from being appended.

-Charles Gagnon (chgagnon@microsoft.com)
Posted by VeritableHero on 8/16/2017 at 11:37 AM
This text shows up when altering stored procedures as well.
Posted by Vladimir Moldovanenko on 8/10/2017 at 11:09 AM
This is pretty useless annoying extra text that I don't need to see and I am sure others too. If there are people that do need it, they should have an option to enable it. It should be off by default