Welcome to dbForumz.com!
FAQFAQ    SearchSearch      ProfileProfile    Private MessagesPrivate Messages   Log inLog in

Aggregation in FastObjects. How to define that in opt file?

 
   Database Forums (Home) -> Object-Oriented RSS
Next:  checking data in one table before updating anothe..  
Author Message
folima

External


Since: Oct 19, 2005
Posts: 1



(Msg. 1) Posted: Wed Oct 19, 2005 2:10 am
Post subject: Aggregation in FastObjects. How to define that in opt file?
Archived from groups: comp>databases>object (more info?)

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


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

 >> Stay informed about: Aggregation in FastObjects. How to define that in opt file? 
Back to top
Login to vote
Display posts from previous:   
Related Topics:
developing a Object Oriented Database -

Help : How to manage stars in database ? - All, Any help would be gratefully appreciated. I have this trouble : In database in one column I have record like that : 000000001 0*6666**66 005555555 Stars could be anything between '0' and '9' So, if I look for this id : 0166662066, it would be..

How to get return type (Resultset) information from databa.. - Hai, For Example Below are two storeprocedures one returns resultset and other not, how get this information through programmatically. 1)CREATE PROCEDURE dbo.UpdateCustomers ( @CustomerID nchar(5), @CompanyName nvarchar(40), @ContactName..

Problems with sorting datas with db4o using orderderAscend.. - Hi, I have created a class "result" with several attributes. Then I have inserted approximately 10000 object result, stored in a yap file. I can get the data and display them. I'd like to know if it is possible, using the functions of db4o, t...

Thinking of going with object db - Hi Folks, Im about to start a new ASP.NET based intranet system that will be used by intially 100 people but in years to come could be 10x that. Ill have a domain model layer and like the idea of not having to write OR mapping layer or paying for a..
   Database Forums (Home) -> Object-Oriented All times are: Pacific Time (US & Canada)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You can edit your posts in this forum
You can delete your posts in this forum
You can vote in polls in this forum



[ Contact us | Terms of Service/Privacy Policy ]