none
Unable to script external tables RRS feed

  • Dotaz

  • In SSMS v18.4 if I right click on an external table and select Script Tables As > CREATE to > New Query Editor Window I get this error.

    TITLE: Microsoft SQL Server Management Studio
    ------------------------------

    RejectType: unknown property. (Microsoft.SqlServer.Smo)

    For help, click: https://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=15.0.18206.0+((SSMS_Rel).191029-2112)&EvtID=RejectType&LinkId=20476

    ------------------------------
    BUTTONS:

    OK

    ------------------------------

    The link it provides doesn't work. If I click on Show Details, I get this:

    ===================================

    RejectType: unknown property. (Microsoft.SqlServer.Smo)

    ------------------------------
    For help, click: https://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=15.0.18206.0+((SSMS_Rel).191029-2112)&EvtID=RejectType&LinkId=20476

    ------------------------------
    Program Location:

       at Microsoft.SqlServer.Management.Smo.SqlPropertyMetadataProvider.PropertyNameToIDLookupWithException(String propertyName, PropertyAccessPurpose pap)
       at Microsoft.SqlServer.Management.Smo.SqlSmoObject.GetPropertyOptional(String propName)
       at Microsoft.SqlServer.Management.Smo.Table.ProcessExternalTableOptionalProperties(StringBuilder script, ScriptingPreferences sp)
       at Microsoft.SqlServer.Management.Smo.Table.GetExternalTableCreationScript(ScriptingPreferences sp, StringBuilder sb)
       at Microsoft.SqlServer.Management.Smo.Table.ScriptCreate(StringCollection queries, ScriptingPreferences sp)
       at Microsoft.SqlServer.Management.Smo.SqlSmoObject.ScriptCreateInternal(StringCollection query, ScriptingPreferences sp, Boolean skipPropagateScript)
       at Microsoft.SqlServer.Management.Smo.ScriptMaker.ScriptCreateObject(Urn urn, ScriptingPreferences sp, ObjectScriptingType& scriptType)
       at Microsoft.SqlServer.Management.Smo.ScriptMaker.ScriptCreate(Urn urn, ScriptingPreferences sp, ObjectScriptingType& scriptType)
       at Microsoft.SqlServer.Management.Smo.ScriptMaker.ScriptCreateObjects(IEnumerable`1 urns)
       at Microsoft.SqlServer.Management.Smo.ScriptMaker.ScriptUrns(List`1 orderedUrns)
       at Microsoft.SqlServer.Management.Smo.ScriptMaker.DiscoverOrderScript(IEnumerable`1 urns)
       at Microsoft.SqlServer.Management.Smo.ScriptMaker.ScriptWorker(List`1 urns, ISmoScriptWriter writer)
       at Microsoft.SqlServer.Management.Smo.ScriptMaker.Script(Urn[] urns, ISmoScriptWriter writer)
       at Microsoft.SqlServer.Management.Smo.ScriptMaker.Script(Urn[] urns)
       at Microsoft.SqlServer.Management.UI.VSIntegration.ObjectExplorer.ScriptGenerator.ScriptCreate(SqlTextWriter sqlwriter, Server server, Urn[] urns, ScriptingOptions options)
       at Microsoft.SqlServer.Management.UI.VSIntegration.ObjectExplorer.ScriptNodeActionContext.Script(SqlTextWriter writer)
       at Microsoft.SqlServer.Management.UI.VSIntegration.ObjectExplorer.SqlScriptMenu.OnScriptItemClick(Object sender, EventArgs e)

    • Přesunutý Tom Phillips středa 20. listopadu 2019 19:30 SSMS question
    středa 20. listopadu 2019 19:20

Odpovědi

  • Hi bwoods90,

    >> RejectType: unknown property. (Microsoft.SqlServer.Smo)

    it seems it is a known issue in SSMS 18.x.

    You could try to script external tables in SSMS 17.9.1, which you could download in here.

    Hope this could help you.

    Best Regards,

    Amelia Gu


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    • Označen jako odpověď bwoods90 čtvrtek 21. listopadu 2019 15:43
    čtvrtek 21. listopadu 2019 7:16