Hello,

I have theses java classes:

- Course
<<key>> code : short
name : string
gratingCurricular : set<Period>

- Period
<<key>> numPeriod : short
anything: set<someThing>

* For each course, there is a collection of Periods
* Period can not exists without a Course (the problem is that i defined on my opt file that Period can exists without a course!! Thats the point... I dont want the Period existing alone)

* I want to do this :

Course.code = 1 and Period.numPeriod = 1
*Course.code = 2 and Period.numPeriod = 1
*Course.code = 3 and Period.numPeriod = 1

However, i cant do that, cuz FastObjects says that "the key(numPeriod) is duplicated"
I would like this kind of error just when inserting like this:

Course.code = 1 and Period.numPeriod = 1
*Course.code = 1 and Period.numPeriod = 1

What do i need to do in the opt file ? (I tried to set the hasExtet of Period to false, but it did not work)

My opt file is like this:

[classes\Course]
persistent = true
hasExtent = true
alias = Course
useIndexes = CourseCodeIndex

[indexes\CourseCodeIndex]
class = Course
members = code
unique = true

[classes\Course\members\gratingCurricular]
itemType = Period
depend = true

[classes\br.unit.si.labbd.unidade2.oo.Period]
persistent = true
hasExtent = false
alias = Period
useIndexes = PeriodCodeIndex

[indexes\PeriodCodeIndex]
class = Period
members = numPeriod
unique = true

Fillipe Lima
Brazil