mrbar2000
unread,Feb 18, 2012, 7:29:41 AM2/18/12Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to dorm, The Delphi ORM
Hi daniele
When I added belongto to Coc Strategy using Owner as convention I
catch a loop when loading the objects. then I see the mapping file of
sample and I discover somethings that raise some doubts.
Why ObjectList sample Laptop.Owner not is defined as a belong to
relation?
Why Owner was´t putted on laptop fields too?
{
...
"TPerson":
{
"package":"BusinessObjects",
"table": "PEOPLE",
"id": {"name":"ID", "field":"ID", "field_type":"integer"},
...
{"name":"Age", "field":"AGE", "field_type":"integer"}
],
"has_many":[{
"name": "Laptops",
"class_name":"TLaptop",
"child_field_name":"PersonID",
"lazy_load": false
}]
},
"TLaptop":
{
"package":"BusinessObjects",
"table": "LAPTOPS",
"id": {"name":"ID", "field":"ID", "field_type":"integer"},
"fields":[
{"name":"Model", "field":"MODEL", "field_type":"string",
"size": 50},
{"name":"RAM", "field":"RAM", "field_type":"integer"},
{"name":"Cores", "field":"NR_OF_CORES",
"field_type":"integer"},
{"name":"PersonID", "field":"ID_PERSON",
"field_type":"integer"}]
}
}