Kaskus

Tech

darkness.espAvatar border
TS
darkness.esp
syntax error
 public String nomor(){
       String urutan = null;
       try {
           kon.rs=kon.st.executeQuery("select right(notransaksi,3)+1" + "from transaksi as nomor order by notransaksi desc");
           if(kon.rs.next()){
               urutan=kon.rs.getString(1);
               while(urutan.length()<3)
                   urutan="0"+urutan;
                   urutan="FK-"+noFormat.format(date)+urutan;
           }else{
               urutan="FK-"+noFormat.format(date)+urutan;
           }
       } catch (Exception e) {
           JOptionPane.showMessageDialog(null, e);
       }
       return urutan;
   }


com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException:You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'as nomor order by notransaksi desc' at line 1




itu erornya dimana ya ? wkwkwk tolong dibantu yak agan" programer
nona212Avatar border
nona212 memberi reputasi
1
598
4
GuestAvatar border
Komentar yang asik ya
Urutan
Terbaru
Terlama
GuestAvatar border
Komentar yang asik ya
Komunitas Pilihan