skip to Main Content

Mysql – MariaDB field + 1

How do I increase a field by +1 that was previously 0001 and then should be 0002? I am currently using the following command: SELECT fieldA+1 FROM table WHERE ID = 1234; But this only turns 0001 into 2 Its…

VIEW QUESTION

How can I use a variable outside while loop in java mysql

String xxx = "Select Totalpay from payments2 where committee_member = '"+memberName+"'"; pst = conn.prepareStatement(xxx); rs = pst.executeQuery(); while(rs.next()) { String totalPayment = rs.getString("TotalPay"); } table.addCell(cell); //String ttlpy = create(); table.addCell(totalPayment); I get the error at table.addCell(totalPayment): variable totalPayment may not…

VIEW QUESTION
Back To Top
Search