회원가입 DB 연동

This commit is contained in:
mcutegs2
2020-06-23 17:52:42 +09:00
parent 939483e336
commit e55cee847a
15 changed files with 208 additions and 100 deletions

View File

@@ -43,16 +43,24 @@ public class UserJoinDao extends BasicDao {
UserJoinVo vo = null;
try {
this.psmt = this.conn.prepareStatement("SELECT * FROM user_tbl WHERE id = ? and pw = ?");
this.psmt.setString(1, member.getU_ID());
this.psmt = this.conn.prepareStatement("SELECT * FROM user_tbl WHERE u_ID ='?' and u_psw ='?'");
//this.psmt = this.conn.prepareStatement("SELECT u_ID, u_psw FROM user_tbl");
// while(this.rs.next()) {
// member = new UserJoinVo();
//member.setU_ID(this.rs.getString("u_ID"));
//member.setU_psw(this.rs.getString("u_psw"));
//}
this.psmt.setString(1, member.getU_ID());
this.psmt.setString(2, member.getU_psw());
this.rs = this.psmt.executeQuery();
this.rs = this.psmt.executeQuery();
if (this.rs.next()) {
vo = new UserJoinVo();
// vo = new UserJoinVo();
String id = this.rs.getString("u_ID");
String pw = this.rs.getString("u_pwd");
vo.setU_ID(id);
vo.setU_psw(pw);
String pw = this.rs.getString("u_psw");
vo = new UserJoinVo(id, pw); // 이거 왜 이러냐 개샤ㅐ끼야
//vo.setU_ID(id);
//vo.setU_psw(pw);
}
} catch (SQLException var5) {
var5.printStackTrace();