how to display  image  retrieved from mysql on JFrame 
I am facing a problem in displaying image that retrieved from database on JFrame. Here is the that i will use,
      .........
              try
               {
               Class.forName("com.mysql.jdbc.Driver");
            Connection con=DriverManager.getConnection("jdbc:mysql://localhost:3306/studio","root","");  
            Statement st=con.createStatement();   
            ResultSet rs = st.executeQuery( "select  image  from photo_instn where cust_id='2'") ;
            while(rs.next()) 
            {
            byte[] imagedata = rs.getBytes("image") ;
            Image img = Toolkit.getDefaultToolkit().createImage(imagedata);
            ImageIcon icon =new ImageIcon(img);
            JLabel lPhoto = new JLabel(icon) ;
            setLayout(null);                              // BYTES TO IMAGE                                                                      
            System.out.println("Inside");
            System.out.println(lPhoto);
            this.add(lPhoto) ;
            lPhoto.setBounds(200,20,300,400); 
  }
}

--------------------------------------------

This code has no problem.but image not displayed on frame...
Please help me for solving this problem....
how to display  image  retrieved from mysql on JFrame 
===

I am facing a problem in displaying image that retrieved from database on JFrame. Here is the that i will use,
      .........
              try
               {
               Class.forName("com.mysql.jdbc.Driver");
            Connection con=DriverManager.getConnection("jdbc:mysql://localhost:3306/studio","root","");  
            Statement st=con.createStatement();   
            ResultSet rs = st.executeQuery( "select  image  from photo_instn where cust_id='2'") ;
            while(rs.next()) 
            {
            byte[] imagedata = rs.getBytes("image") ;
            Image img = Toolkit.getDefaultToolkit().createImage(imagedata);
            ImageIcon icon =new ImageIcon(img);
            JLabel lPhoto = new JLabel(icon) ;
            setLayout(null);                              // BYTES TO IMAGE                                                                      
            System.out.println("Inside");
            System.out.println(lPhoto);
            this.add(lPhoto) ;
            lPhoto.setBounds(200,20,300,400); 
  }
}

--------------------------------------------

This code has no problem.but image not displayed on frame...
Please help me for solving this problem....