• 2022-06-26
    根据用户在文本框txtName中输入的姓名对Student表进行查询,以下SQL语句定义正确的是__________________。
    A: String sql=Select * from Student where Sname=+txtName.getText();
    B: String sql=Select * from Student where Sname='+txtName.getText()+';
    C: String sql=Select * from Student where Sname like +txtName.getText();
    D: String sql=Select * from Student where Sname like '+txtName.getText()+';
  • 举一反三