I am trying to validate a username and password to my system using AES_ENCRYPT and AES_DECRYPT, however when logging in I get a error

Code:
ERROR: Column Index out of range, 3 > 2.
Login Code
Code:
 try {
            con = DriverManager.getConnection(url+dbName,userName,password);
            System.out.println("Connected to the database");
            Statement st = con.createStatement();
            ResultSet rt = st.executeQuery("SELECT AES_DECRYPT(`userPassword`, 'enigma') AS password, accessLevel FROM accounts WHERE username=('"+userNameE+"')");
           while(rt.next()){
             passwordCheck = rt.getString(3);
             userNameCheck = rt.getString(1);
             accessLevel = rt.getInt(2);
           if (userNameCheck.equals(userNameE) && passwordCheck.equals(passwordE)){
            if(accessLevel == 1){
                   mu.setVisible(true);
                   mu.jButton1.setEnabled(false);
                    mu.jButton2.setEnabled(false);
                   loginFail = false;
                   con.close();}
            if(accessLevel == 2){
                  mu.setVisible(true);
                  mu.jButton5.setEnabled(false);
                  loginFail = false;
                   con.close();
            }
            System.out.println("Disconnected from database");
               this.dispose();
            }
              
        }
Also for creating a user, is this correct, because when I was created a user before, it would validate it, but when I created a user using the MySQL command client, it seemed to validate that instead of the java version.

Code:
public void createUser(){

         if(jTextField1.getText().isEmpty() == false && jPasswordField2.getPassword().toString().isEmpty() == false &&
           jPasswordField1.getPassword().toString().isEmpty())
         if(!jPasswordField2.getPassword().equals(jPasswordField1.getPassword())){
                         new Menu().setVisible(true);
         }
         
         {
             try{
               con = DriverManager.getConnection(url+dbName,userName,password);
                  System.out.println("Connected to the database");
               PreparedStatement pst = con.prepareStatement("INSERT INTO accounts (username, accessLevel, userPassword) VALUES (?,?,AES_ENCRYPT('"+jPasswordField1.getPassword()+"', 'enigma')");
               pst.setString(1, jTextField1.getText());
               pst.setInt(2, accessLevel);
               pst.executeUpdate();
                        con.close();
                          System.out.println("Disconnected from database");
                                new Menu().setVisible(true);
                                this.dispose();
             } catch (SQLException e) {System.err.println("ERROR: " + e.getMessage()); }
         }

   
    }