Please note: this project is inactive since early 2006

 
2.5.3.1 Primary keys

You define a primary key like this:

  <entity ...>
    <primaryKey attributeName='...'/>
    ...
  </entity>

The <primaryKey> tag only has one attribute, attributeName, which needs to have the same value as one the entity's attributes' names. We will see how an attribute is described in the next section, however we can already tell that an attribute used as a primary key is often defined like:

    <attribute name='id' type='int' 
               isClassProperty='0' isRequired='1'
               columnName='ID' externalType='INTEGER'/>

Comments are welcome: Sebastien Bigaret / Modeling Home Page
Hosted by:SourceForge.net Logo