Announcement Announcement Module
Collapse
No announcement yet.
Database initialization Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Database initialization

    I'd like to use Java constants (public static final) to be able to make comparisions like myProcess.getState.equals(ProcessState.CLOSED), but I'd also like them to be in the database. In my example, I'd have a ProcessState table which would have every possible state.

    Does Spring + Hibernate support that database initialization somehow?

  • #2
    I don't see how it can be in Java as a static and at the same time dynamic in the database.
    Last edited by karldmoore; Aug 29th, 2007, 12:08 PM.

    Comment


    • #3
      Those are values needed at the database just read-only, they won't change.

      Comment


      • #4
        I appreciate what you are saying. You could model the values as normal immutable entities, but they aren't static they've come from the database.
        Last edited by karldmoore; Aug 29th, 2007, 12:07 PM.

        Comment

        Working...
        X