数据库部署问题 [英] Database Deployment issues

查看:173
本文介绍了数据库部署问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个很难部署我的网站。
我经历了一些错误,并得到了他们得到了解决,我成功发布自己的网站,但是当我尝试打开它给我的任何页面404或500错误

I'm having a hard time deploying my website. I got through some errors and they got resolved and I successfully published my website but when I try to open any page it gives me 404 or 500 Error

我的主机提供商告诉我,如果这个页面是使用一个数据库,它不是部署,那么这是可能是问题
所以我想我的部署数据库和我得到的connectionString错误。

My host provider told me that if this page is using a database and it's not deployed then this is might be the problem so I tried to deploy my database and I get the connectionString error.

问题是,我不存储我的connectionString在web.config
它保存在我的基地DAL类的属性和它的使用的所有的DAL类
所以我更新,但我得到同样的错误

The problem is that I'm not storing my connectionString in the web.config It's stored in a property in my base DAL class and it's used by all the DAL classes so I updated it but I get the same error

我不知道什么是错的,我应该包括在web.config中的connectionString?

I dont know what's wrong, should I include the connectionString in the web.config ?

N.B :当我建立了包,我尝试设置主动模式释放它返回的设置,以调试!

N.B When I build the package and I try to set the active mode to 'release' it returns the setting to 'debug'!

推荐答案

我很抱歉,但所有的答案告诉我,我需要把的ConnectionString在Web.config文件,但实际上,整个问题得到解决时,我将自己的应用程序的虚拟目录,我没有需要改变我的DAL层或添加任何东西到web.config

I'm sorry but all the answers advised me that I need to place the 'ConnectionString' in 'Web.config' but actually the whole problem was solved when I added my application to a virtual directory and I didn't need to change my DAL layer or add anything to the web.config

当然,我从你的答案和我AP preciate学到了,但没有我不需要在我的web.config添加任何东西。如果我决定让这个设计模式。

Of course I learned from your answers and I appreciate it but no I don't need to add anything in my web.config If I decided to have this design pattern.

这篇关于数据库部署问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆