ID

Uploaded

Status

Description

Work Items

Action

18064
by TheDanishDynamo
Jan 8, 2016
3:15 PM

Being evaluated

Handle general exception

try
{
//Call the "Script" method of sqlSmoObject (which may or may not exist)
object[] invokeMemberArgs = { scriptingOptions };
objectStatements =
sqlSmoObject.GetType().InvokeMember("Script",
BindingFlags.Public | BindingFlags.Instance |
BindingFlags.InvokeMethod, null, sqlSmoObject, invokeMemberArgs)
as
StringCollection;
}
catch (MissingMethodException)
{
writeStdError("Object doesn't provide Script method:" + urn.Type + ", " + sqlSmoObject);
return;
}
catch (Exception ex)
{
writeStdError(ex.Message);
return;
}

Download

18063
by TheDanishDynamo
Jan 8, 2016
1:23 AM

Being evaluated

Ignore: Invalid path: There is no collection of UnresolvedEntity objects that is a child of Database.

Download

12043
by Joreiser
Apr 24, 2012
8:47 AM

Being evaluated

Adds support for usage of username and password switches.

Download

257
by lukev
Sep 2, 2007
7:57 PM

Being evaluated

Added these commandline options:
/uiet - use IF..EXISTS statements when scripting tables
/se - skip an object if an exception (other than Missing Method) is thrown during scripting
/tf:(template.file) - Added the ability to include a template file. We use a standard changelog header in all our procs. I've added three variables that can be replaced: The actual script body, the date and the object name that's being scripted.

Download

414
by JayTurnerIII
Oct 24, 2007
7:35 PM

Applied

It seems that certain ideas are popular. I to added the ability to script a drop statement in the output data. I on the other hand put a drop before every object. This is feature is the thing I would want the Microsoft scripting software to do, not put all of the drops at the beging of the data but just before the object that is to be dropped. Thank you for your time and I hope you will not find my code to unprofessional as I needed the drop statements and just hacked away at your code to get what I needed.


Applied Jan 18, 2008: Added script drop.

Download

331
by rmbuda
Sep 27, 2007
2:38 PM

Applied

Extended properties on Primary Key only works for v9 + so added version check
Add error handling for connection failure
Add an IF EXISTS(...) DROP xxx for those objects not scripted with IF NOT EXISTS (except for tables)
Fixed a bug in database creation script. Should use CleanStatements(databaseStatements)

scriptingOptions.IncludeDatabaseRoleMemberships = true (Important for Users)
Change defaults:
outputType = OutputType.Tree
scriptSchemaQualify = true
scriptExendedProperties = true


Applied Jan 18, 2008: Included some default changes. Server v+9 check. DROP option delayed to future release.

Download

View All
  • 1-6 of 6 Patches
    • Previous
    • 1
    • Next
    • Showing
    • All
    • Patches