I'm dealing with some model classes with some fields that have been declared as enum's. Allis well and happy in my little application world - _however_ we are not the sole users of the database and as such, other status's may appear in those enumerated fields.
Using @Enumerated(EnumType.STRING) with the proper enum type causes an exception. In a number of places we've had to change them to String fields and define final static values for comparison.
Thoughts / ideas on a solution that would allow my application to treat them as Enum's yet fail gracefully (eg: default value / skip record ... ) ?
Thanks,
Using @Enumerated(EnumType.STRING) with the proper enum type causes an exception. In a number of places we've had to change them to String fields and define final static values for comparison.
Thoughts / ideas on a solution that would allow my application to treat them as Enum's yet fail gracefully (eg: default value / skip record ... ) ?
Thanks,