0

i have a number with format "C99999"

i need import it to sql

i try this

while (rs.next()){
         int s=rs.getInt("Number");
        s++;

        String n = String.format("%05d",s);
        view.txtcustomernumber.setText(n);

how to add "C" into this format and the data type in mysql is int

Yuuki Rito
  • 17
  • 5

1 Answers1

0

Just use "C%05d" as the format string.

C. K. Young
  • 219,335
  • 46
  • 382
  • 435