DXA 2.1 Upgrade Content Import Fails Due to TemplatePurpose Property












1














We're completing the final steps of an upgrade from Web 8.5 to Sites 9 and from DXA 2.0 to 2.1. Most of the steps have succeeded so far (upgrading databases, upgrading CM and CD to Sites 9, etc.) - following the documentation here and here. We've come to the point when it is time to upgrade DXA on the Content Manager by running an import PowerShell command. However, when we run the import command, as per the documentation, we get an error message saying:



[Error] Tridion.ContentManager.InvalidActionException: Property 'TemplatePurpose' can not be updated



PS C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cms> .cms-import.ps1 -importType master-only -cmsUrl "http://localhost/
"
Installed CMS version reported to be 9.0.0.609
Copied 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsDXA Application Data Definition.xml' to 'C:Program Files (x86)
SDL WebconfigImportExportApplicationData'
Preparing upgrade to DXA 1.6 structure...
Folder '/webdav/100%20Master/Building%20Blocks/Framework' already exists; it seems that your CMS already has DXA 1.6 str
ucture.
Specify the -force flag if you want the run the upgrade anyways.
checking /webdav/100%20Master/Building%20Blocks/Framework/Developer/Templates/DXA%2EUpgrade
Folder '/webdav/100%20Master/Building%20Blocks/Framework/Developer/Templates/DXA%2EUpgrade' already exists; it seems tha
t your CMS already has DXA 2.0 structure.
Specify the -force flag if you want the run the upgrade anyways.
Uploading package 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaster-only.zip' ...
Importing content ...
Aborted
2018/12/11 23:59:07 <141> [Information] Import process '7ae73a7a0c3345b4b8c4b7c3c185e869' is started by 'KCPSdjewett' a
t 12/11/2018 11:59:07 PM.
2018/12/11 23:59:07 <141> [Information] Building list of items to import and determining required import actions.
2018/12/11 23:59:07 <141> [Information] Unzipping and initializing package for import.
2018/12/11 23:59:11 <141> [Information] Import items into publication '000 Empty' started at 12/11/2018 11:59:11 PM.
2018/12/11 23:59:11 <141> [Information] Import items into publication '100 Master' started at 12/11/2018 11:59:11 PM.
2018/12/11 23:59:12 <141> [Error] Tridion.ContentManager.InvalidActionException: Property 'TemplatePurpose' can not be u
pdated
at Tridion.ContentManager.CommunicationManagement.TemplateBuildingBlock.OnSaving(SaveEventArgs eventArgs)
at Tridion.ContentManager.IdentifiableObject.Save(SaveEventArgs eventArgs)
at Tridion.ContentManager.ContentManagement.VersionedItem.Save(Boolean checkInAfterSave)
at Tridion.ContentManager.ImportExport.ImportAction.<>c__DisplayClass30_0.<SaveItem>b__0(Boolean isRetry)
at Tridion.ContentManager.ImportExport.Process.<>c__DisplayClass35_0.<InvokeInErrorHandler>b__0(Boolean isRetry)
at Tridion.ContentManager.ImportExport.AbortErrorHandler.Invoke[T](Func`2 function, LocalizableMessage message, Boole
an retryAvailable, Boolean isCritical, UserReply additionalUserReplyOptions)
at Tridion.ContentManager.ImportExport.Process.InvokeInErrorHandler[T](Func`2 function, LocalizableMessage message, B
oolean retryAvailable, Boolean isCritical)
at Tridion.ContentManager.ImportExport.ImportAction.SaveItem(IdentifiableObject item, IdentifiableObjectData deltaObj
ect)
at Tridion.ContentManager.ImportExport.UpdateImportAction.Perform(IdentifiableObjectData itemData)
at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
ry`2 unresolvedDependencies, Boolean specialImport)
at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
ry`2 unresolvedDependencies, Boolean specialImport)
at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
ry`2 unresolvedDependencies, Boolean specialImport)
at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
ry`2 unresolvedDependencies, Boolean specialImport)
at Tridion.ContentManager.ImportExport.Importer.ImportItems(IList`1 items, Boolean specialGroupImport)
at Tridion.ContentManager.ImportExport.Importer.Import(String packageName)
2018/12/11 23:59:12 <141> [Information] Transactional import failed at 12/11/2018 11:59:12 PM. No changes were committed
to SDL Web Content Manager.
An error occured while importing 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaster-only.zip'
At C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0ImportExportContentManagerUtils.ps1:422 char:9
+ throw "An error occured while importing '$packageFullPath'"
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : OperationStopped: (An error occure...aster-only.zip':String) , RuntimeException
+ FullyQualifiedErrorId : An error occured while importing 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaste
r-only.zip'




Some additional information:



After some investigation, it appears this property is a new property introduced to the CM database in Sites 9, as I see the column for it after having upgraded our CM database. And the DXA 2.1 import package also contains the field:



enter image description here



However, it seems that because the values currently in the CM database are all null, the import is blocked from overwriting existing rows. I can run a SQL statement to enumerate which templates have the null TemplatePurpose and which are likely the culprits:



enter image description here



It turns out, the templates causing the issue are all of the templates in the 100 Master/Building Blocks/Framework/Developer/Templates/DXA.Legacy and DXA.R2 folders:



enter image description here










share|improve this question



























    1














    We're completing the final steps of an upgrade from Web 8.5 to Sites 9 and from DXA 2.0 to 2.1. Most of the steps have succeeded so far (upgrading databases, upgrading CM and CD to Sites 9, etc.) - following the documentation here and here. We've come to the point when it is time to upgrade DXA on the Content Manager by running an import PowerShell command. However, when we run the import command, as per the documentation, we get an error message saying:



    [Error] Tridion.ContentManager.InvalidActionException: Property 'TemplatePurpose' can not be updated



    PS C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cms> .cms-import.ps1 -importType master-only -cmsUrl "http://localhost/
    "
    Installed CMS version reported to be 9.0.0.609
    Copied 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsDXA Application Data Definition.xml' to 'C:Program Files (x86)
    SDL WebconfigImportExportApplicationData'
    Preparing upgrade to DXA 1.6 structure...
    Folder '/webdav/100%20Master/Building%20Blocks/Framework' already exists; it seems that your CMS already has DXA 1.6 str
    ucture.
    Specify the -force flag if you want the run the upgrade anyways.
    checking /webdav/100%20Master/Building%20Blocks/Framework/Developer/Templates/DXA%2EUpgrade
    Folder '/webdav/100%20Master/Building%20Blocks/Framework/Developer/Templates/DXA%2EUpgrade' already exists; it seems tha
    t your CMS already has DXA 2.0 structure.
    Specify the -force flag if you want the run the upgrade anyways.
    Uploading package 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaster-only.zip' ...
    Importing content ...
    Aborted
    2018/12/11 23:59:07 <141> [Information] Import process '7ae73a7a0c3345b4b8c4b7c3c185e869' is started by 'KCPSdjewett' a
    t 12/11/2018 11:59:07 PM.
    2018/12/11 23:59:07 <141> [Information] Building list of items to import and determining required import actions.
    2018/12/11 23:59:07 <141> [Information] Unzipping and initializing package for import.
    2018/12/11 23:59:11 <141> [Information] Import items into publication '000 Empty' started at 12/11/2018 11:59:11 PM.
    2018/12/11 23:59:11 <141> [Information] Import items into publication '100 Master' started at 12/11/2018 11:59:11 PM.
    2018/12/11 23:59:12 <141> [Error] Tridion.ContentManager.InvalidActionException: Property 'TemplatePurpose' can not be u
    pdated
    at Tridion.ContentManager.CommunicationManagement.TemplateBuildingBlock.OnSaving(SaveEventArgs eventArgs)
    at Tridion.ContentManager.IdentifiableObject.Save(SaveEventArgs eventArgs)
    at Tridion.ContentManager.ContentManagement.VersionedItem.Save(Boolean checkInAfterSave)
    at Tridion.ContentManager.ImportExport.ImportAction.<>c__DisplayClass30_0.<SaveItem>b__0(Boolean isRetry)
    at Tridion.ContentManager.ImportExport.Process.<>c__DisplayClass35_0.<InvokeInErrorHandler>b__0(Boolean isRetry)
    at Tridion.ContentManager.ImportExport.AbortErrorHandler.Invoke[T](Func`2 function, LocalizableMessage message, Boole
    an retryAvailable, Boolean isCritical, UserReply additionalUserReplyOptions)
    at Tridion.ContentManager.ImportExport.Process.InvokeInErrorHandler[T](Func`2 function, LocalizableMessage message, B
    oolean retryAvailable, Boolean isCritical)
    at Tridion.ContentManager.ImportExport.ImportAction.SaveItem(IdentifiableObject item, IdentifiableObjectData deltaObj
    ect)
    at Tridion.ContentManager.ImportExport.UpdateImportAction.Perform(IdentifiableObjectData itemData)
    at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
    ry`2 unresolvedDependencies, Boolean specialImport)
    at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
    ry`2 unresolvedDependencies, Boolean specialImport)
    at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
    ry`2 unresolvedDependencies, Boolean specialImport)
    at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
    ry`2 unresolvedDependencies, Boolean specialImport)
    at Tridion.ContentManager.ImportExport.Importer.ImportItems(IList`1 items, Boolean specialGroupImport)
    at Tridion.ContentManager.ImportExport.Importer.Import(String packageName)
    2018/12/11 23:59:12 <141> [Information] Transactional import failed at 12/11/2018 11:59:12 PM. No changes were committed
    to SDL Web Content Manager.
    An error occured while importing 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaster-only.zip'
    At C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0ImportExportContentManagerUtils.ps1:422 char:9
    + throw "An error occured while importing '$packageFullPath'"
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : OperationStopped: (An error occure...aster-only.zip':String) , RuntimeException
    + FullyQualifiedErrorId : An error occured while importing 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaste
    r-only.zip'




    Some additional information:



    After some investigation, it appears this property is a new property introduced to the CM database in Sites 9, as I see the column for it after having upgraded our CM database. And the DXA 2.1 import package also contains the field:



    enter image description here



    However, it seems that because the values currently in the CM database are all null, the import is blocked from overwriting existing rows. I can run a SQL statement to enumerate which templates have the null TemplatePurpose and which are likely the culprits:



    enter image description here



    It turns out, the templates causing the issue are all of the templates in the 100 Master/Building Blocks/Framework/Developer/Templates/DXA.Legacy and DXA.R2 folders:



    enter image description here










    share|improve this question

























      1












      1








      1







      We're completing the final steps of an upgrade from Web 8.5 to Sites 9 and from DXA 2.0 to 2.1. Most of the steps have succeeded so far (upgrading databases, upgrading CM and CD to Sites 9, etc.) - following the documentation here and here. We've come to the point when it is time to upgrade DXA on the Content Manager by running an import PowerShell command. However, when we run the import command, as per the documentation, we get an error message saying:



      [Error] Tridion.ContentManager.InvalidActionException: Property 'TemplatePurpose' can not be updated



      PS C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cms> .cms-import.ps1 -importType master-only -cmsUrl "http://localhost/
      "
      Installed CMS version reported to be 9.0.0.609
      Copied 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsDXA Application Data Definition.xml' to 'C:Program Files (x86)
      SDL WebconfigImportExportApplicationData'
      Preparing upgrade to DXA 1.6 structure...
      Folder '/webdav/100%20Master/Building%20Blocks/Framework' already exists; it seems that your CMS already has DXA 1.6 str
      ucture.
      Specify the -force flag if you want the run the upgrade anyways.
      checking /webdav/100%20Master/Building%20Blocks/Framework/Developer/Templates/DXA%2EUpgrade
      Folder '/webdav/100%20Master/Building%20Blocks/Framework/Developer/Templates/DXA%2EUpgrade' already exists; it seems tha
      t your CMS already has DXA 2.0 structure.
      Specify the -force flag if you want the run the upgrade anyways.
      Uploading package 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaster-only.zip' ...
      Importing content ...
      Aborted
      2018/12/11 23:59:07 <141> [Information] Import process '7ae73a7a0c3345b4b8c4b7c3c185e869' is started by 'KCPSdjewett' a
      t 12/11/2018 11:59:07 PM.
      2018/12/11 23:59:07 <141> [Information] Building list of items to import and determining required import actions.
      2018/12/11 23:59:07 <141> [Information] Unzipping and initializing package for import.
      2018/12/11 23:59:11 <141> [Information] Import items into publication '000 Empty' started at 12/11/2018 11:59:11 PM.
      2018/12/11 23:59:11 <141> [Information] Import items into publication '100 Master' started at 12/11/2018 11:59:11 PM.
      2018/12/11 23:59:12 <141> [Error] Tridion.ContentManager.InvalidActionException: Property 'TemplatePurpose' can not be u
      pdated
      at Tridion.ContentManager.CommunicationManagement.TemplateBuildingBlock.OnSaving(SaveEventArgs eventArgs)
      at Tridion.ContentManager.IdentifiableObject.Save(SaveEventArgs eventArgs)
      at Tridion.ContentManager.ContentManagement.VersionedItem.Save(Boolean checkInAfterSave)
      at Tridion.ContentManager.ImportExport.ImportAction.<>c__DisplayClass30_0.<SaveItem>b__0(Boolean isRetry)
      at Tridion.ContentManager.ImportExport.Process.<>c__DisplayClass35_0.<InvokeInErrorHandler>b__0(Boolean isRetry)
      at Tridion.ContentManager.ImportExport.AbortErrorHandler.Invoke[T](Func`2 function, LocalizableMessage message, Boole
      an retryAvailable, Boolean isCritical, UserReply additionalUserReplyOptions)
      at Tridion.ContentManager.ImportExport.Process.InvokeInErrorHandler[T](Func`2 function, LocalizableMessage message, B
      oolean retryAvailable, Boolean isCritical)
      at Tridion.ContentManager.ImportExport.ImportAction.SaveItem(IdentifiableObject item, IdentifiableObjectData deltaObj
      ect)
      at Tridion.ContentManager.ImportExport.UpdateImportAction.Perform(IdentifiableObjectData itemData)
      at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
      ry`2 unresolvedDependencies, Boolean specialImport)
      at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
      ry`2 unresolvedDependencies, Boolean specialImport)
      at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
      ry`2 unresolvedDependencies, Boolean specialImport)
      at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
      ry`2 unresolvedDependencies, Boolean specialImport)
      at Tridion.ContentManager.ImportExport.Importer.ImportItems(IList`1 items, Boolean specialGroupImport)
      at Tridion.ContentManager.ImportExport.Importer.Import(String packageName)
      2018/12/11 23:59:12 <141> [Information] Transactional import failed at 12/11/2018 11:59:12 PM. No changes were committed
      to SDL Web Content Manager.
      An error occured while importing 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaster-only.zip'
      At C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0ImportExportContentManagerUtils.ps1:422 char:9
      + throw "An error occured while importing '$packageFullPath'"
      + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      + CategoryInfo : OperationStopped: (An error occure...aster-only.zip':String) , RuntimeException
      + FullyQualifiedErrorId : An error occured while importing 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaste
      r-only.zip'




      Some additional information:



      After some investigation, it appears this property is a new property introduced to the CM database in Sites 9, as I see the column for it after having upgraded our CM database. And the DXA 2.1 import package also contains the field:



      enter image description here



      However, it seems that because the values currently in the CM database are all null, the import is blocked from overwriting existing rows. I can run a SQL statement to enumerate which templates have the null TemplatePurpose and which are likely the culprits:



      enter image description here



      It turns out, the templates causing the issue are all of the templates in the 100 Master/Building Blocks/Framework/Developer/Templates/DXA.Legacy and DXA.R2 folders:



      enter image description here










      share|improve this question













      We're completing the final steps of an upgrade from Web 8.5 to Sites 9 and from DXA 2.0 to 2.1. Most of the steps have succeeded so far (upgrading databases, upgrading CM and CD to Sites 9, etc.) - following the documentation here and here. We've come to the point when it is time to upgrade DXA on the Content Manager by running an import PowerShell command. However, when we run the import command, as per the documentation, we get an error message saying:



      [Error] Tridion.ContentManager.InvalidActionException: Property 'TemplatePurpose' can not be updated



      PS C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cms> .cms-import.ps1 -importType master-only -cmsUrl "http://localhost/
      "
      Installed CMS version reported to be 9.0.0.609
      Copied 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsDXA Application Data Definition.xml' to 'C:Program Files (x86)
      SDL WebconfigImportExportApplicationData'
      Preparing upgrade to DXA 1.6 structure...
      Folder '/webdav/100%20Master/Building%20Blocks/Framework' already exists; it seems that your CMS already has DXA 1.6 str
      ucture.
      Specify the -force flag if you want the run the upgrade anyways.
      checking /webdav/100%20Master/Building%20Blocks/Framework/Developer/Templates/DXA%2EUpgrade
      Folder '/webdav/100%20Master/Building%20Blocks/Framework/Developer/Templates/DXA%2EUpgrade' already exists; it seems tha
      t your CMS already has DXA 2.0 structure.
      Specify the -force flag if you want the run the upgrade anyways.
      Uploading package 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaster-only.zip' ...
      Importing content ...
      Aborted
      2018/12/11 23:59:07 <141> [Information] Import process '7ae73a7a0c3345b4b8c4b7c3c185e869' is started by 'KCPSdjewett' a
      t 12/11/2018 11:59:07 PM.
      2018/12/11 23:59:07 <141> [Information] Building list of items to import and determining required import actions.
      2018/12/11 23:59:07 <141> [Information] Unzipping and initializing package for import.
      2018/12/11 23:59:11 <141> [Information] Import items into publication '000 Empty' started at 12/11/2018 11:59:11 PM.
      2018/12/11 23:59:11 <141> [Information] Import items into publication '100 Master' started at 12/11/2018 11:59:11 PM.
      2018/12/11 23:59:12 <141> [Error] Tridion.ContentManager.InvalidActionException: Property 'TemplatePurpose' can not be u
      pdated
      at Tridion.ContentManager.CommunicationManagement.TemplateBuildingBlock.OnSaving(SaveEventArgs eventArgs)
      at Tridion.ContentManager.IdentifiableObject.Save(SaveEventArgs eventArgs)
      at Tridion.ContentManager.ContentManagement.VersionedItem.Save(Boolean checkInAfterSave)
      at Tridion.ContentManager.ImportExport.ImportAction.<>c__DisplayClass30_0.<SaveItem>b__0(Boolean isRetry)
      at Tridion.ContentManager.ImportExport.Process.<>c__DisplayClass35_0.<InvokeInErrorHandler>b__0(Boolean isRetry)
      at Tridion.ContentManager.ImportExport.AbortErrorHandler.Invoke[T](Func`2 function, LocalizableMessage message, Boole
      an retryAvailable, Boolean isCritical, UserReply additionalUserReplyOptions)
      at Tridion.ContentManager.ImportExport.Process.InvokeInErrorHandler[T](Func`2 function, LocalizableMessage message, B
      oolean retryAvailable, Boolean isCritical)
      at Tridion.ContentManager.ImportExport.ImportAction.SaveItem(IdentifiableObject item, IdentifiableObjectData deltaObj
      ect)
      at Tridion.ContentManager.ImportExport.UpdateImportAction.Perform(IdentifiableObjectData itemData)
      at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
      ry`2 unresolvedDependencies, Boolean specialImport)
      at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
      ry`2 unresolvedDependencies, Boolean specialImport)
      at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
      ry`2 unresolvedDependencies, Boolean specialImport)
      at Tridion.ContentManager.ImportExport.Importer.ImportItem(WebDavUrl exportUrl, IList`1 dependentItemsChain, Dictiona
      ry`2 unresolvedDependencies, Boolean specialImport)
      at Tridion.ContentManager.ImportExport.Importer.ImportItems(IList`1 items, Boolean specialGroupImport)
      at Tridion.ContentManager.ImportExport.Importer.Import(String packageName)
      2018/12/11 23:59:12 <141> [Information] Transactional import failed at 12/11/2018 11:59:12 PM. No changes were committed
      to SDL Web Content Manager.
      An error occured while importing 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaster-only.zip'
      At C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0ImportExportContentManagerUtils.ps1:422 char:9
      + throw "An error occured while importing '$packageFullPath'"
      + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      + CategoryInfo : OperationStopped: (An error occure...aster-only.zip':String) , RuntimeException
      + FullyQualifiedErrorId : An error occured while importing 'C:installSDL.DXA.NET.2.1SDL.DXA.NET.2.1.0cmsmaste
      r-only.zip'




      Some additional information:



      After some investigation, it appears this property is a new property introduced to the CM database in Sites 9, as I see the column for it after having upgraded our CM database. And the DXA 2.1 import package also contains the field:



      enter image description here



      However, it seems that because the values currently in the CM database are all null, the import is blocked from overwriting existing rows. I can run a SQL statement to enumerate which templates have the null TemplatePurpose and which are likely the culprits:



      enter image description here



      It turns out, the templates causing the issue are all of the templates in the 100 Master/Building Blocks/Framework/Developer/Templates/DXA.Legacy and DXA.R2 folders:



      enter image description here







      dxa upgrade sites-9 dxa-2.1






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked 4 hours ago









      Damian Jewett

      778310




      778310






















          1 Answer
          1






          active

          oldest

          votes


















          1














          One workaround I've found is to temporarily move all of the aforementioned templates into temporary new folder locations, to allow the import operation to succeed. Then, once the cms-import.ps1 script is successfully run, the new templates will be in the correct location. Finally, to make this work, it's necessary to compare each of the new templates to the corresponding older versions, using Where Used to update any dependencies to point to the new templates. All-in-all, this approach works well, I've been able to run and test the DXA 2.1 web application and it's relatively non-time-consuming (takes about a couple hours max).






          share|improve this answer





















          • Note also that there is a new TBB called "Extract Components from Regions"
            – Damian Jewett
            4 hours ago











          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "485"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftridion.stackexchange.com%2fquestions%2f19652%2fdxa-2-1-upgrade-content-import-fails-due-to-templatepurpose-property%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          1














          One workaround I've found is to temporarily move all of the aforementioned templates into temporary new folder locations, to allow the import operation to succeed. Then, once the cms-import.ps1 script is successfully run, the new templates will be in the correct location. Finally, to make this work, it's necessary to compare each of the new templates to the corresponding older versions, using Where Used to update any dependencies to point to the new templates. All-in-all, this approach works well, I've been able to run and test the DXA 2.1 web application and it's relatively non-time-consuming (takes about a couple hours max).






          share|improve this answer





















          • Note also that there is a new TBB called "Extract Components from Regions"
            – Damian Jewett
            4 hours ago
















          1














          One workaround I've found is to temporarily move all of the aforementioned templates into temporary new folder locations, to allow the import operation to succeed. Then, once the cms-import.ps1 script is successfully run, the new templates will be in the correct location. Finally, to make this work, it's necessary to compare each of the new templates to the corresponding older versions, using Where Used to update any dependencies to point to the new templates. All-in-all, this approach works well, I've been able to run and test the DXA 2.1 web application and it's relatively non-time-consuming (takes about a couple hours max).






          share|improve this answer





















          • Note also that there is a new TBB called "Extract Components from Regions"
            – Damian Jewett
            4 hours ago














          1












          1








          1






          One workaround I've found is to temporarily move all of the aforementioned templates into temporary new folder locations, to allow the import operation to succeed. Then, once the cms-import.ps1 script is successfully run, the new templates will be in the correct location. Finally, to make this work, it's necessary to compare each of the new templates to the corresponding older versions, using Where Used to update any dependencies to point to the new templates. All-in-all, this approach works well, I've been able to run and test the DXA 2.1 web application and it's relatively non-time-consuming (takes about a couple hours max).






          share|improve this answer












          One workaround I've found is to temporarily move all of the aforementioned templates into temporary new folder locations, to allow the import operation to succeed. Then, once the cms-import.ps1 script is successfully run, the new templates will be in the correct location. Finally, to make this work, it's necessary to compare each of the new templates to the corresponding older versions, using Where Used to update any dependencies to point to the new templates. All-in-all, this approach works well, I've been able to run and test the DXA 2.1 web application and it's relatively non-time-consuming (takes about a couple hours max).







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered 4 hours ago









          Damian Jewett

          778310




          778310












          • Note also that there is a new TBB called "Extract Components from Regions"
            – Damian Jewett
            4 hours ago


















          • Note also that there is a new TBB called "Extract Components from Regions"
            – Damian Jewett
            4 hours ago
















          Note also that there is a new TBB called "Extract Components from Regions"
          – Damian Jewett
          4 hours ago




          Note also that there is a new TBB called "Extract Components from Regions"
          – Damian Jewett
          4 hours ago


















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Tridion Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.





          Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


          Please pay close attention to the following guidance:


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftridion.stackexchange.com%2fquestions%2f19652%2fdxa-2-1-upgrade-content-import-fails-due-to-templatepurpose-property%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          What visual should I use to simply compare current year value vs last year in Power BI desktop

          How to ignore python UserWarning in pytest?

          Alexandru Averescu