I had a LocalTime field (using Joda Time) in the Grails domain class.
Class WorkDone{ LocalTime duration }
Now I have changed this field to String (with text limitation) so that it can support a duration of more than 24 hours.
String duration
The problem is that the database already has some data. And I want to misinform this data through database migration in Grails. I use Postgres, which saves LocalTime as Bytea (binary data).
When I call WorkDone.duration, it returns me a form line:
\ xaced0005737200176f72672e6a6f64612e74696d652e4c6f63616c54696d65fffff44abbf29def0200024a000c694c6f63616c4d696c6c69734c000b694368726f6e6f6c6f677974001a4c6f72672f6a6f64612f74696d652f4368726f6e6f6c6f67793b78700000000000000000737200276f72672e6a6f64612e74696d652e6368726f6e6f2e49534f4368726f6e6f6c6f67792453747562a9c811667137502703000078707372001f6f72672e6a6f64612e74696d652e4461746554696d655a6f6e652453747562a62f019a7c321ae30300007870770500035554437878
How can I extract time from this line?
source share