1 Reply Latest reply on Nov 29, 2011 1:49 AM by Jason Porter

    Security: support for ENUMs?

    Karsten Wutzke Expert


      I've recently integrated Seam 3 Security into one of my projects. What I don't like is the fact that Seam 3 Security seems to rely on certain tables to be present. Correct me if I'm wrong, but I couldn't get it to work when omitting unnecessary tables, e.g. CredentialType. I currently only use passwords.

      Is it really that Seam 3 requires all properties to be mapped to tables and that these tables must be present in the DB? Sometimes, it's simply not possible to change the DB and sometimes I don't really want to add n tables for something I don't need/use. It only bloats DB designs.

      Since I'm mostly using MySQL, I often avoid lookup tables (like all the XType ones in the module) by defining columns of type ENUM('one', 'two', 'three'), which is just a sorted, constrained string type, much like a Standard SQL VARCHAR(n) CHECK (column_name IN ('one', 'two', 'three')) string type.

      So my question is: are there any plans to support MySQL (and maybe other DBMSs) ENUM's in the future instead of requiring integrators to create lookup tables? Can it be done already?