Im using this code to get image from SQLITE
try{
String sql = "SELECT Photo FROM Pics WHERE InvoiceNumber=?";
pst = conn.prepareStatement(sql);
rs=pst.executeQuery();
if(rs.next()){
byte[]imagedata = rs.getBytes("Photo");
format = new ImageIcon(imagedata);
ImIc.setIcon(format);
}
}catch(Exception e){
JOptionPane.showMessageDialog(null, e);
}
private ImageIcon format = null;
String filename = null;
int s=0;
byte[] bill_image = null;
how to fix this?
I get no result