T
Thomas Kellerer
Hi,
I need to convert a timestamp value in a string (from a text file that I
need to import into the database) into a java.util.Date object.
The problem is, that I the format of the input string does not seem to
match any of the possibilities that I have with SimpleDateFormat:
The input value is, e.g.: 2007-11-27T14:55:40-08:00
The problem I have, is with the non-standard timezone offset at the end.
I cannot find any pattern for SimpleDateFormat to parse the time portion
correctly. For the beginning it would also be sufficient if I could
simply make SimpleDateFormat ignore that part.
Note that I cannot change the input value (e.g. with substring) so I am
looking for a format model that covers the above input string.
Currently I don't think it's possible, but maybe there is someone out
there who has a brilliant idea
Cheers
Thomas
I need to convert a timestamp value in a string (from a text file that I
need to import into the database) into a java.util.Date object.
The problem is, that I the format of the input string does not seem to
match any of the possibilities that I have with SimpleDateFormat:
The input value is, e.g.: 2007-11-27T14:55:40-08:00
The problem I have, is with the non-standard timezone offset at the end.
I cannot find any pattern for SimpleDateFormat to parse the time portion
correctly. For the beginning it would also be sufficient if I could
simply make SimpleDateFormat ignore that part.
Note that I cannot change the input value (e.g. with substring) so I am
looking for a format model that covers the above input string.
Currently I don't think it's possible, but maybe there is someone out
there who has a brilliant idea
Cheers
Thomas