
I am getting this error when i am compiling this code. java.sql.SQLException: ORA-00904: "PASS": invalid identifier
ackage com.jlcindia.bookstore.register; import java.sql.*; import java.util.List;
import com.jlcindia.bookstore.forgot.*; import com.jlcindia.jdbc.JDBCUTILNew; public class Register extends Forgot { Connection con=null; //Statement st=null; PreparedStatement ps=null; Forgot fr=new Forgot(); public int getBooksByCat(){ int x=0; try{ con=JDBCUTILNew.getConnection();
ps=con.prepareStatement("insert into register(fname, lname, email, phone, gender, ctype, cnum, fcol, uname, pass, repword) values(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)");
ps.setString(1,fr.getFname());
ps.setString(2,fr.getLname());
ps.setString(3,fr.getEmail());
ps.setString(4,fr.getPhone());
ps.setString(5,fr.getGender());
ps.setString(6, fr.getCtype());
ps.setString(7,fr.getCnum());
ps.setString(8,fr.getColor());
ps.setString(9,fr.getUname());
ps.setString(10,fr.getPass());
ps.setString(11,fr.getRepword());
x= ps.executeUpdate();
} catch(Exception e){ System.out.println(e); } finally{ JDBCUTILNew.close(con, ps); } return x; } }
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.