blanzk
blanzk
2021-03-08 15:45

没报错但是数据库没更新是怎么回事

<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:ConnectionString %>" SelectCommand="SELECT * FROM [information] WHERE ([username] = @username)" UpdateCommand="UPDATE information SET username = @username, password = @password, email = @email, sex = @sex, aeg = @aeg, ps = @ps">
<SelectParameters>
<asp:SessionParameter Name="username" SessionField="us" Type="String" />
</SelectParameters>
<UpdateParameters>
<asp:ControlParameter ControlID="username" Name="username" PropertyName="Text" />
<asp:ControlParameter ControlID="password1" Name="password" PropertyName="Text" />
<asp:ControlParameter ControlID="email" Name="email" PropertyName="Text" />
<asp:SessionParameter Name="sex" SessionField="sex" />
<asp:ControlParameter ControlID="age" Name="aeg" PropertyName="Text" />
<asp:ControlParameter ControlID="ps" Name="ps" PropertyName="Text" />
</UpdateParameters>
</asp:SqlDataSource>

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 复制链接分享
  • 邀请回答

为你推荐