Create subtype to maintain distinct column definitions

About this task

When you extend a lookup table entity, the new column is added to all lookup table definitions that use that entity. If the column does not apply to all lookup tables, then define a subtype of the entity, and define the column on that subtype.

For example, if you want to extend the lookup table with a BodyType column for personal vehicle coverage terms, you must create a new subtype. Create a new PAVehicleCovTermLookup entity extension subtype and add the BodyType column. Do not add the BodyType column to the CovTermLookup entity extension, because it does not apply to all coverage terms.

Procedure

  1. Define a new entity in configuration > config > extensions > entity as follows:

    Property

    Value

    Entity

    PAVehicleCovTermLookup

    Entity Type

    subtype

    Supertype

    CovTermLookup

  2. Add a typekey element to the new entity with the following parameters:

    Property

    Value

    name

    BodyType

    typelist

    BodyType

  3. In lookuptables.xml for PAVehicleCovTerm, use PAVehicleCovTermLookup instead of CovTermLookup:
      <LookupTable code="PAVehicleCovTerm" entityName="PAVehicleCovTermLookup" root="PersonalVehicle"> 
        <Filter field="PolicyLinePatternCode" valuePath="PersonalVehicle.PALine.PatternCode"/> 
        ...
        <Dimension field="JobType" valuePath="PersonalVehicle.PALine.Branch.Job.Subtype" precedence="2"/> 
        <Dimension field="BodyType" valuePath="PersonalVehicle.BodyType" precedence="3"/> 
        <DistinguishingField field="CovTermPatternCode"/> 
      </LookupTable>