[Flow] Validation > Exception instead of going back to newAction

Alexander Berl a.berl at outlook.com
Mon Dec 9 11:11:34 CET 2013


Hi Axel,

maybe you can go a little different way about the core problem with the NLS:
create your own Doctrine Type that formats the DateTime correctly,
similar to how timezone is handled here:
http://docs.doctrine-project.org/en/2.0.x/cookbook/working-with-datetime.html

or try to override the doctrine oracle platform getDateFormatString
method (not sure if you could just implement your own platform)
https://github.com/doctrine/dbal/blob/5514917bde7fdb0dafc4bff61322bb39d7b7ad9f/lib/Doctrine/DBAL/Platforms/OraclePlatform.php#L666

Then use Flow DateTime objects and set date and time as Bastian suggested.

Regards,
Alexander

Am 06.12.2013 17:20, schrieb Axel Wüstemann:
> Am 06.12.2013 16:35, schrieb Stephen Bungert:
>> Can't you just output the date with the correct format?
>>
> 
> I have german dates in the datebase, or better oracle intarnally
> formatted datetimes, but due to the NLS setting, it will be received by
> the client (doctrine here) as german formated date time.
> 
> So I would get the error:
> 
> Could not convert database value "14.10.13 05:10" to Doctrine Type
> datetime. Expected format: Y-m-d H:i:s
> 
> Thos things normally could be treated in the select statement (to_char
> or to_date) -  but this is not the idea of doctrine.


More information about the Flow mailing list