Ver Mensaje Individual
  #1  
Antiguo 26-07-2006
Puche Puche is offline
Miembro
 
Registrado: may 2004
Posts: 10
Reputación: 0
Puche Va por buen camino
Smile Fechas en Firebird

Hola a todos. Trabajo con delphi7, bde e firebird. Cuando asigno una fecha a un campo de la base de datos, me devuelve este error. Es algo muy raro, ya que, en algunos casos, he detectado que si la asigno desde un edit (pj ttempes['fecha_creacion'] := edfecha99.text) funciona. En cambio cuando hago algo así ttempes['fecha_creacion']:=date, me salta el error:

0.0 is not a valid timestamp



La estructura de la tabla es:
create table TEMPESC(
CONCEPTO varchar(10) not null,
ARTICULO varchar(20),
CLASE varchar(20),
CONSUMO double precision,
COSTE T_YESNO DEFAULT 'False',
TOTAL double precision,
ORIGEN varchar(20),
CLASE_ORIGEN varchar(20),
IMPRESION smallint,
PRECIO double precision,
FECHA_CREACION timestamp,
INCLUIR T_YESNO DEFAULT 'False',
TIPO varchar(10),
PORCENTAJE T_YESNO DEFAULT 'False',
MARGEN T_YESNO DEFAULT 'False',
CANTIDAD double precision DEFAULT 0,
FECHA_CONSUMO timestamp,
PORCENTAJE2 char(1),
MARGEN2 char(1),
SECCION varchar(10));

/* Primary Key */
alter table TEMPESC add constraint TEMPESC_PRIMARY primary key (CONCEPTO);

/* Indexes */
create index IMPRI on TEMPESC(IMPRESION);
create index ESCANDALLO on TEMPESC(TIPO, PORCENTAJE2, MARGEN2, CONCEPTO);

Gracias por vuestro tiempo. Un saludo
Responder Con Cita