1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
|
String requeteNbrClient =
"Select Count(distinct cli) from commande " +"where ref=? and Fact <>0";
ResultSet table;
int countClient;
int countMonture;
try
{
Variables.pStat = Variables.connection.prepareStatement(
requeteNbrClient);
Variables.pStat.setString(1, ref);
table = Variables.pStat.executeQuery(requeteNbrClient);// c"est ici que se trouve l'erreur
table.next();
countClient = table.getInt(1);
table.close();
Variables.pStat.close();
}
catch (SQLException e) { e.printStackTrace();
return null;} |
Partager