Joseg,
Josber, el tipo
Date en las bases de datos es un binario
Integer.
En Unix Date el campo contiene segundos a partir del 1 de Enero de 1970:
Tiempo Unix - Wikipedia, la enciclopedia libre
Si no me equivoco, en las BD provenientes de la familia Unix, se usa este sistema. Y es el motor de la BD que lo presenta en un formato u otro, el que deseemos.
En DB2 la cosa cambia:
IBM Knowledge Center
Citación del post de IBM
|
❞
Internally to DB2, the date is represented as a 4 byte field, with each byte containing 2 packed decimal digits stored in the format yyyymmdd.
Externally, as returned by an SQL SELECT statement, the date is represented by a character field. The format of the string is dependant on the DATE parameter in the DB2 DSNHDECP installation module (the DB2 installation option specified on the installation panel DSNTIP4). Table 24 shows valid DB2 date formats. The length of the date field is 10 bytes, except where the DB2 Installation Date format is LOCAL, in which case the length is installation-dependent and in the range 10 to 254 bytes. The date value must be in the range 0001-01-01 to 9999-12-31 (ISO format).
|
Y aquí información para MySQL:
MySQL :: MySQL Internals Manual :: 10.9 Date and Time Data Type Representation
Cita:
|
❞
DATE - 3 bytes, little endian
TIMESTAMP - 4 bytes, little endian
|
O sea que el tipo DATE de MySQL no es posible usarlo con Fujitsu ya que trabaja con binarios byte-oriented:
Binary or COMP Format, a Description and Discussion
Es decir, no podemos declarar un binario de 3 bytes en Fujitsu. En Micro Focus sí podemos.
Conclusión: Usar campos de tiempo
Timestamp que son de 4 bytes
PIC S9(9) COMP-5.