Re: Importing an EOModel with single table inheritance

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Mon Mar 05 2007 - 06:15:43 EST

  • Next message: Simon McLean: "Re: Importing an EOModel with single table inheritance"

    Hi Simon,

    Looking at the code, it fails not because of single-table
    inheritance, but still I think this is a bug in Cayenne. Could you
    please open a bug report and attach your EOModel to it - I'd like to
    investigate more.

    http://issues.apache.org/cayenne/

    Thanks
    Andrus

    On Mar 4, 2007, at 8:10 PM, Simon wrote:

    > Hi -
    >
    > I'm trying to import an EOModel with cayenne Modeler and i'm
    > getting the exception pasted below. ABSTRACT_FOP is a table that
    > has a super entity and 2 sub entities mapped to it.
    >
    > Is it not possible to import an EOModel that has single-table
    > inheritance ?
    >
    > Thanks, Simon
    >
    >
    > CayenneModeler Info
    > Version: 2.0.2
    > Build Date: January 14 2007
    > Exception:
    > =================================
    > org.apache.cayenne.CayenneRuntimeException: [v.2.0.2 January 14
    > 2007] One and only one entity should be mapped to ABSTRACT_FOP.
    > Instead found : 3
    > at
    > org.apache.cayenne.wocompat.EOModelProcessor.makeFlatRelationships
    > (EOModelProcessor.java:661)
    > at org.apache.cayenne.wocompat.EOModelProcessor.loadEOModel
    > (EOModelProcessor.java:171)
    > at org.apache.cayenne.wocompat.EOModelProcessor.loadEOModel
    > (EOModelProcessor.java:117)
    > at
    > org.apache.cayenne.modeler.action.ImportEOModelAction.importEOModel
    > (ImportEOModelAction.java:125)
    > at
    > org.apache.cayenne.modeler.action.ImportEOModelAction.performAction
    > (ImportEOModelAction.java:89)
    > at org.apache.cayenne.modeler.util.CayenneAction.actionPerformed
    > (CayenneAction.java:163)
    > at javax.swing.AbstractButton.fireActionPerformed
    > (AbstractButton.java:1882)
    > at javax.swing.AbstractButton$Handler.actionPerformed
    > (AbstractButton.java:2202)
    > at javax.swing.DefaultButtonModel.fireActionPerformed
    > (DefaultButtonModel.java:420)
    > at javax.swing.DefaultButtonModel.setPressed
    > (DefaultButtonModel.java:258)
    > at javax.swing.AbstractButton.doClick(AbstractButton.java:334)
    > at apple.laf.ScreenMenuItem.actionPerformed(ScreenMenuItem.java:104)
    > at java.awt.MenuItem.processActionEvent(MenuItem.java:597)
    > at java.awt.MenuItem.processEvent(MenuItem.java:556)
    > at java.awt.MenuComponent.dispatchEventImpl(MenuComponent.java:298)
    > at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:286)
    > at java.awt.EventQueue.dispatchEvent(EventQueue.java:466)
    > at java.awt.EventDispatchThread.pumpOneEventForHierarchy
    > (EventDispatchThread.java:269)
    > at java.awt.EventDispatchThread.pumpEventsForHierarchy
    > (EventDispatchThread.java:190)
    > at java.awt.EventDispatchThread.pumpEvents
    > (EventDispatchThread.java:184)
    > at java.awt.EventDispatchThread.pumpEvents
    > (EventDispatchThread.java:176)
    > at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
    >
    >
    >
    >



    This archive was generated by hypermail 2.0.0 : Mon Mar 05 2007 - 06:16:30 EST