One of the post installation steps of installing Sitecore Commerce 9 on PaaS is to Update Data Templates from Commerce ribbon in Content Editor.

Unfortunately, this is ending with exception.

[![enter image description here][1]][1]

> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.ArgumentNullException: Value cannot be null. Parameter name: key at System.Collections.Concurrent.ConcurrentDictionary`2.ContainsKey(TKey key) at Sitecore.Commerce.Engine.Connect.DataProvider.CatalogRepository.GetEntityView(String sitecoreId, String viewName, String forAction, String itemId) at Sitecore.Commerce.Engine.Connect.DataProvider.Templates.CatalogTemplateGenerator.BuildCatalogTemplates(Database database) --- End of inner exception stack trace --- at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor) at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at Sitecore.Reflection.ReflectionUtil.InvokeMethod(MethodInfo method, Object[] parameters, Object obj) at Sitecore.Jobs.JobRunner.RunMethod(JobArgs args) at (Object , Object[] ) at Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args) at Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain) at Sitecore.Jobs.Job.DoExecute() at Sitecore.Jobs.Job.ThreadEntry(Object state)


I navigated to "/sitecore/Commerce/Catalog Management/Catalogs" and field "SelectedCatalogs" is empty. I suspect that this is causing trouble but I don;t know how to make it fulfilled. 

As this field is empty, it is also causing trouble with Default Catalog Setting item located in "/sitecore/Commerce/Settings/Catalog/Default Catalog":

[![enter image description here][2]][2]

I have clicked "Refresh Commerce Cache" couple of times and also restarted services in Azure PaaS. Nothing helped so far.

I can see catalogs for each environment without any problem in Business Tools (bizfx):

[![enter image description here][3]][3]


  [1]: https://i.sstatic.net/h0eit.png
  [2]: https://i.sstatic.net/w6UGW.png
  [3]: https://i.sstatic.net/ZUqUs.png