My solution:
NodeIterator iNodes= cloud.getList(null, "A,related,A", null, null,
null, null, "destination", false).nodeIterator();
Then iterate and retrieve the relation nodes one by one using:
Node related = iNodes().nextNode().getNodeValue("related");
One problem may be that the second step may result in separate queries
for each relation that is retrieved.
This can be overcome by first collecting all the nodenumbers:
int relatedNumber = iNodes.nextNode.getIntValue("related.number")
Then construct a commaseparated string of these numbers, and retrieve
all objects A in one go using a constraint like "NUMBER in (...)".
Rob van Maris
Technical Consultant
Quantiq
xmedia & communication solutions
Koninginneweg 11-13
1217 KP Hilversum
T +31 (0)356257211
M +31 (0)651444006
E [EMAIL PROTECTED]
W http://www.quantiq.com
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Ronald Wildenberg
Sent: donderdag 21 oktober 2004 10:18
To: [EMAIL PROTECTED]
Subject: Fetching relations from the MMBase cloud
Hi,
I have a problem retrieving relations from an MMBase cloud. I have the
following (simplified) cloud model:
A - related - A
A - related - B
I wish to retrieve all 'related' relations between A and A.