MySQL更新后面的代码问题 [英] Problem with code behind update to MySQL
本文介绍了MySQL更新后面的代码问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
好的大家,当我使用它后面的代码执行此更新子句时,给我一个愚蠢的错误,上面写着:
行:6
字符:62099
错误:Sys.WebForms.PageRequestManagerServerErrorExceptio n:初始化字符串的格式不符合从索引0开始的规范。
代码:0
网址: http:// localhost:1038 / webapp / admin / assignuser.aspx
现在,我的SQL代码背后的代码是:
展开 | 选择 | Wrap | 行号
解决方案
我认为问题是你的连接字符串。您正在传递文字字符串SqlDataSource4连接对象。
MySql conn字符串应该类似于
展开 | 选择 | 换行 | 行号
< blockquote>当我使用上面的代码时,即使我有dbowner,它也会给我一个登录失败。我正在使用的登录工作在其他地方,所以我真的不确定什么是错的。
你能为我发布更新的代码吗?感谢。
Ok everyone, when I do this update clause using code behind it gives me a stupid error that says:
Line: 6
Char: 62099
Error: Sys.WebForms.PageRequestManagerServerErrorExceptio n: Format of the initialization string does not conform to specification starting at index 0.
Code: 0
URL: http://localhost:1038/webapp/admin/assignuser.aspx
Now, my code for the SQL code behind is:
Expand|Select|Wrap|Line Numbers解决方案I think the problem is your connection string. You are passing the literal string "SqlDataSource4" to the connection object.
A MySql conn string should look something like
Expand|Select|Wrap|Line Numbers
When I use the code above, it gives me a logon failure even though I have dbowner. The logon I''m using works everywhere else so I''m really not sure what''s wrong.
Can you post your updated code for me? Thanks.
这篇关于MySQL更新后面的代码问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文登录 关闭
扫码关注1秒登录发送“验证码”获取 | 15天全站免登陆