vb.net簡單的數據庫聯接問題解决办法
vb.net簡單的數據庫聯接問題
行 1: '. ' 附近的語法不正確。
描述: 在執行目前 Web 要求的過程中發生未處理的例外情形。請檢閱堆疊追蹤以取得錯誤的詳細資訊,以及在程式碼中產生的位置。
例外詳細資訊: System.Data.SqlClient.SqlException: 行 1: '. ' 附近的語法不正確。
原始程式錯誤:
行 60: 'cmdRe.CommandText = Sql3
行 61: cmdRe = New SqlCommand(Sql3, conn)
行 62: drRe = cmdRe.ExecuteReader()
行 63:
行 64: 'Get Email
原始程式檔: D:\WEB\newecrecn\Login.aspx.vb 行: 62
堆疊追蹤:
[SqlException: 行 1: '. ' 附近的語法不正確。]
System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream)
System.Data.SqlClient.SqlCommand.ExecuteReader()
newecrecn.login.Page_Load(Object sender, EventArgs e) in D:\WEB\newecrecn\Login.aspx.vb:62
System.Web.UI.Control.OnLoad(EventArgs e)
System.Web.UI.Control.LoadRecursive()
System.Web.UI.Page.ProcessRequestMain()
請問大家這個問題是怎麽導致的哦,在綫等。。。
------解决方案--------------------
可能是Sql3错了,能看一下么?
行 1: '. ' 附近的語法不正確。
描述: 在執行目前 Web 要求的過程中發生未處理的例外情形。請檢閱堆疊追蹤以取得錯誤的詳細資訊,以及在程式碼中產生的位置。
例外詳細資訊: System.Data.SqlClient.SqlException: 行 1: '. ' 附近的語法不正確。
原始程式錯誤:
行 60: 'cmdRe.CommandText = Sql3
行 61: cmdRe = New SqlCommand(Sql3, conn)
行 62: drRe = cmdRe.ExecuteReader()
行 63:
行 64: 'Get Email
原始程式檔: D:\WEB\newecrecn\Login.aspx.vb 行: 62
堆疊追蹤:
[SqlException: 行 1: '. ' 附近的語法不正確。]
System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream)
System.Data.SqlClient.SqlCommand.ExecuteReader()
newecrecn.login.Page_Load(Object sender, EventArgs e) in D:\WEB\newecrecn\Login.aspx.vb:62
System.Web.UI.Control.OnLoad(EventArgs e)
System.Web.UI.Control.LoadRecursive()
System.Web.UI.Page.ProcessRequestMain()
請問大家這個問題是怎麽導致的哦,在綫等。。。
------解决方案--------------------
可能是Sql3错了,能看一下么?