problems formatting a timestamp

I have a timestamp column (mysql) in a table that doesn’t
display correctly in servoy.

I’ve tried all the predefined format selections, but my dates
look something like this on the screen:

04/26/0606 (this should be a date from the past week or so)

can servoy format timestamp fields? or am I missing something?? :?

thanks in advance.
rm.

Good question… :?

Hello Robert

I’m setting the format patterns with a method and it works without problems:

‘displayformat|editformat’ →
‘yyyy.MM.dd HH:mm:ss|yyyy.MM.dd HH:mm:ss’

This then looks as follows: “2006.02.13 11:32:13”

Gruss
hpm

Sybase ASA
Servoy 2.2.4

Maybe you need to change the date format on the mySQL database server? I vaguely remeber having to do this on either a mySql or Postgres installation in the past.

what happens if you just dump the value in a normal textfield without any formatting?

thanks to all who responded;

with Gruss’s suggestion, I get this: 0603.09.01 00:00:00

when outputting the field with no format, as suggested by
Johan, I get: 01-09-0603

when displaying the data from the mysql command line utility,
I get: 06021219014000000000

:?

thats a very very strange number
A bit large if i look what date it becomes this in java:

Fri Oct 29 08:13:20 CEST 190806804

don’t think we have reached that yet.

yes, this is all very strange.

by the way, if I output the field with the mysql command
line utility, formatting it with the DATE() function, it come
out correctly…

and what is exactly the column type reported by mysql tool and servoy?
And if you make in servoy another date colum besides it what is then the type?

the mysql tool show the field as “timestamp(19)”

servoy shows the field as “DATETIME”

after creating a new field in servoy, and specifing it as “DATETIME”,
the mysql utility shows the new field as “datetime”.

has anyone given this any thought?

we’re still experiencing the problem.

thanks.
rm.

anybody??

we’re still expreiencing this problem;

if anyone could assist, we’d be greatful.

thanks.
rm.

RobertMeyer:
the mysql tool show the field as “timestamp(19)”

servoy shows the field as “DATETIME”

after creating a new field in servoy, and specifing it as “DATETIME”,
the mysql utility shows the new field as “datetime”.

Hi Robert, I tried using PostgreSQL intervals in Servoy and it got confused!

I suspect Servoy does not know what do with a timestamp(19).
You could alter the field on your sql database to a simple ‘timestamp’ and will probably work fine.

thanks, swingman; that sounds like a good plan.

rm.