鈥?鈥濆簲鐢ㄧ▼搴忎腑鐨勬湇鍔″櫒閿欒銆侟hr width=100% size=1 color=silver>

鍦ㄤ笌 SQL Server 寤虹珛杩炴帴鏃跺嚭鐜颁笌缃戠粶鐩稿叧鐨勬垨鐗瑰畾浜庡疄渚嬬殑閿欒銆傛湭鎵惧埌鎴栨棤娉曡闂湇鍔″櫒銆傝楠岃瘉瀹炰緥鍚嶇О鏄惁姝g‘骞朵笖 SQL Server 宸查厤缃负鍏佽杩滅▼杩炴帴銆 (provider: TCP 鎻愪緵绋嬪簭, error: 0 - 鐢变簬鐩爣璁$畻鏈虹Н鏋佹嫆缁濓紝鏃犳硶杩炴帴銆?

璇存槑: 鎵ц褰撳墠 Web 璇锋眰鏈熼棿锛屽嚭鐜版湭澶勭悊鐨勫紓甯搞€傝妫€鏌ュ爢鏍堣窡韪俊鎭紝浠ヤ簡瑙f湁鍏宠閿欒浠ュ強浠g爜涓鑷撮敊璇殑鍑哄鐨勮缁嗕俊鎭€

寮傚父璇︾粏淇℃伅: System.Data.SqlClient.SqlException: 鍦ㄤ笌 SQL Server 寤虹珛杩炴帴鏃跺嚭鐜颁笌缃戠粶鐩稿叧鐨勬垨鐗瑰畾浜庡疄渚嬬殑閿欒銆傛湭鎵惧埌鎴栨棤娉曡闂湇鍔″櫒銆傝楠岃瘉瀹炰緥鍚嶇О鏄惁姝g‘骞朵笖 SQL Server 宸查厤缃负鍏佽杩滅▼杩炴帴銆 (provider: TCP 鎻愪緵绋嬪簭, error: 0 - 鐢变簬鐩爣璁$畻鏈虹Н鏋佹嫆缁濓紝鏃犳硶杩炴帴銆?

婧愰敊璇?


琛 44:     protected void Page_Load(object sender, EventArgs e)
琛 45:     {
琛 46:         SqlDataReader drtt = DbHelperSQL.ExecuteReader("select * from t_title where id=1");
琛 47:         while (drtt.Read())
琛 48:         {

婧愭枃浠碟 d:\www\web\hzcjtz\wwwroot\news.aspx.cs    琛孃 46

鍫嗘爤璺熻釜:


[SqlException (0x80131904): 鍦ㄤ笌 SQL Server 寤虹珛杩炴帴鏃跺嚭鐜颁笌缃戠粶鐩稿叧鐨勬垨鐗瑰畾浜庡疄渚嬬殑閿欒銆傛湭鎵惧埌鎴栨棤娉曡闂湇鍔″櫒銆傝楠岃瘉瀹炰緥鍚嶇О鏄惁姝g‘骞朵笖 SQL Server 宸查厤缃负鍏佽杩滅▼杩炴帴銆 (provider: TCP 鎻愪緵绋嬪簭, error: 0 - 鐢变簬鐩爣璁$畻鏈虹Н鏋佹嫆缁濓紝鏃犳硶杩炴帴銆?]
   Maticsoft.DBUtility.DbHelperSQL.ExecuteReader(String strSQL) +200
   news.Page_Load(Object sender, EventArgs e) in d:\www\web\hzcjtz\wwwroot\news.aspx.cs:46
   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
   System.Web.UI.Control.OnLoad(EventArgs e) +99
   System.Web.UI.Control.LoadRecursive() +50
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627


鐗堟湰淇℃伅: Microsoft .NET Framework 鐗堟湰:2.0.50727.8745; ASP.NET 鐗堟湰:2.0.50727.8745
Baidu
sogou