InvalidVersionEnumeratorException: Operation not supported on SQL Server 2005.

Jan 30, 2012 at 11:00 PM
Edited Jan 30, 2012 at 11:00 PM

 

How do I get past this?
C:\Users\administrator>ExportSQLScript.exe localhost test_db /ot:Tree /of:Cr eationOrder.txt /od:"outdir" /ssq Getting objects: ApplicationRole Getting objects: ServiceBroker Getting objects: Default Getting objects: ExtendedStoredProcedure Getting objects: FullTextCatalog Getting objects: MessageType Getting objects: PartitionFunction Getting objects: PartitionScheme Getting objects: DatabaseRole Getting objects: RemoteServiceBinding Getting objects: Rule Getting objects: Schema Getting objects: ServiceContract Getting objects: ServiceQueue Getting objects: ServiceRoute Getting objects: SqlAssembly Getting objects: StoredProcedure Getting objects: Synonym Getting objects: Table Getting objects: User Getting objects: UserDefinedAggregate Getting objects: UserDefinedDataType Getting objects: UserDefinedFunction Getting objects: UserDefinedType Getting objects: View Getting objects: XmlSchemaCollection Getting objects: SymmetricKey Getting objects: Certificate Getting objects: AsymmetricKey Getting objects: UserDefinedTableTypes Unhandled Exception: Microsoft.SqlServer.Management.Smo.FailedOperationException : Enum objects failed for Database 'test_db'. ---> Microsoft.SqlServer.Mana gement.Sdk.Sfc.InvalidVersionEnumeratorException: Operation not supported on SQL Server 2005.
Apr 24, 2012 at 9:00 AM
Edited Apr 24, 2012 at 9:01 AM

In config.cs change

[KeyValueCommandLineOption("xt")] protected internal String excludeTypes = "";

to

[KeyValueCommandLineOption("xt")] protected internal String excludeTypes = "UserDefinedTableTypes";

Rebuild, and you're fine!