连接到Azure数据库

连接到Azure数据库,azure,umbraco,azure-sql-database,Azure,Umbraco,Azure Sql Database,我有一个使用SQL CE开发的Umbraco站点,然后我将其更改为SQLEXPRESS,并可以在本地连接到这两个站点。我部署到Azure(最初使用CE)并且一切正常,然后我创建了一个SQL Azure数据库并将SQLEXPRESS复制到那里,这似乎同样有效,我可以使用SQL Management Studio连接到SQL Azure数据库 当我尝试从我的应用程序连接到Azure db时,问题出现了。我已经使用Azure连接字符串更新了web.config,但是在本地和Azure中我都得到了- V

我有一个使用SQL CE开发的Umbraco站点,然后我将其更改为SQLEXPRESS,并可以在本地连接到这两个站点。我部署到Azure(最初使用CE)并且一切正常,然后我创建了一个SQL Azure数据库并将SQLEXPRESS复制到那里,这似乎同样有效,我可以使用SQL Management Studio连接到SQL Azure数据库

当我尝试从我的应用程序连接到Azure db时,问题出现了。我已经使用Azure连接字符串更新了web.config,但是在本地和Azure中我都得到了-

Value cannot be null.
Parameter name: sqlSyntax 
  Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

 Exception Details: System.ArgumentNullException: Value cannot be null.
Parameter name: sqlSyntax

Source Error: 


 An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.  

Stack Trace: 



[ArgumentNullException: Value cannot be null.
Parameter name: sqlSyntax]
   Umbraco.Core.Persistence.Repositories.PetaPocoRepositoryBase`2..ctor(IDatabaseUnitOfWork work, CacheHelper cache, ILogger logger, ISqlSyntaxProvider sqlSyntax) +120
   Umbraco.Core.Persistence.Repositories.DomainRepository..ctor(IDatabaseUnitOfWork work, CacheHelper cache, ILogger logger, ISqlSyntaxProvider sqlSyntax) +23
   Umbraco.Core.Services.DomainService.GetAll(Boolean includeWildcards) +75
   Umbraco.Web.Routing.PublishedContentRequestEngine.FindDomain() +286
   Umbraco.Web.Routing.PublishedContentRequestEngine.PrepareRequest() +15
   Umbraco.Web.UmbracoModule.ProcessRequest(HttpContextBase httpContext) +361
   Umbraco.Web.UmbracoModule.<Init>b__8(Object sender, EventArgs e) +80
   System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +141
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +69
值不能为空。
参数名称:sqlSyntax
描述:执行当前web请求期间发生未处理的异常。请查看堆栈跟踪以了解有关错误的更多信息以及错误在代码中的起源。
异常详细信息:System.ArgumentNullException:值不能为null。
参数名称:sqlSyntax
源错误:
在执行当前web请求期间生成了未经处理的异常。有关异常的起源和位置的信息可以使用下面的异常堆栈跟踪来识别。
堆栈跟踪:
[ArgumentNullException:值不能为null。
参数名称:sqlSyntax]
Umbraco.Core.Persistence.Repositories.PetaPocoRepositoryBase`2..ctor(IDatabaseUnitOfWork、CacheHelper缓存、ILogger记录器、ISqlSyntaxProvider sqlSyntax)+120
Umbraco.Core.Persistence.Repositories.DomainRepository..ctor(IDatabaseUnitOfWork、CacheHelper缓存、ILogger记录器、ISqlSyntaxProvider sqlSyntax)+23
Umbraco.Core.Services.DomainService.GetAll(布尔值includeWildcards)+75
Umbraco.Web.Routing.PublishedContentRequestEngine.FindDomain()+286
Umbraco.Web.Routing.PublishedContentRequestEngine.PrepareRequest()+15
Umbraco.Web.UmbracoModule.ProcessRequest(HttpContextBase httpContext)+361
Umbraco.Web.Umbraco.b__8(对象发送方,事件参数e)+80
System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()+141
System.Web.HttpApplication.ExecuteStep(IExecutionStep步骤,布尔值&同步完成)+69

有什么问题吗?

我对翁布拉科不太熟悉,但你是否了解他们网站上的内容

在MSDN上也引用了Azure


顺便说一句,他们还提供了一个在Azure上运行的产品。

我不熟悉Umbraco,但您是否遵循了他们网站上的建议

在MSDN上也引用了Azure


作为补充说明,他们还有一个在Azure上运行的产品。

如果web.config包含空的umbracoDbDSN密钥,但umbracoConfigurationStatus密钥已填充,则会发生此错误。即:

<appSettings>
  <add key="umbracoConfigurationStatus" value="7.3.4" />
  ...
</appSettings>
<connectionStrings>
  <add name="umbracoDbDSN" connectionString="" providerName="" />
  ...
</connectionStrings>

...
...
双重检查umbracodsn连接字符串和providerName。您可以通过清空web.config中的umbracoConfigurationStatus值,尝试在SQL Azure数据库中重新安装Umbraco

替换

<add key="umbracoConfigurationStatus" value="7.3.4" />


当web.config包含一个空的umbracoDbDSN键,但填写了umbracoConfigurationStatus键时,会发生此错误。即:

<appSettings>
  <add key="umbracoConfigurationStatus" value="7.3.4" />
  ...
</appSettings>
<connectionStrings>
  <add name="umbracoDbDSN" connectionString="" providerName="" />
  ...
</connectionStrings>

...
...
双重检查umbracodsn连接字符串和providerName。您可以通过清空web.config中的umbracoConfigurationStatus值,尝试在SQL Azure数据库中重新安装Umbraco

替换

<add key="umbracoConfigurationStatus" value="7.3.4" />