Ver Mensaje Individual
  #3 (permalink)  
Antiguo 21/05/2009, 17:50
Avatar de rockex
rockex
 
Fecha de Ingreso: diciembre-2008
Mensajes: 45
Antigüedad: 15 años, 4 meses
Puntos: 0
Respuesta: Ingresar fecha en un campo date

y como puedo aplicarlo a mi codigo =s
que realmente no pude aplicarlo =/
este es mi codigo

Código:

String FechaX=jcb_diaX.getSelectedItem()+"/"+jcb_mesX.getSelectedItem()+"/"+jcb_añoX.getSelectedItem();//Carga La fecha de emision
       
        //ACTUALIZACION DE DATOS
        CargaBase();
        try {
                        
        String Ingreso2="INSERT INTO productosx (id,nombre,cantidad,fecha) VALUES('"+jtf_id.getText()+"','"+jtf_nombre.getText()+"','"+jtf_cant.getText()+"','"+FechaX+"');";
        sentencia.executeUpdate(Ingreso2);//Operador Que Ingresa
                //Ingreso A La tabla Registro                               
                msj.showMessageDialog(null, "Producto: "+jtf_id.getText()+" Registrado","Registro",JOptionPane.INFORMATION_MESSAGE);//Mensaje
                 
                con.close();//Cierre de Ingreso 
        
              } catch(SQLException e) //Capturador de Errores
            {
                msj.showMessageDialog(null, "Error"+e,"Error",JOptionPane.INFORMATION_MESSAGE);//Mensajes de error 
            }
ayuda plis =/