Hi Rie,

A Criteria is evaluated to return a list of records for an existing table (as long as 
your working with Torque objects and not Village records), i.e you don't work with a 
joined table:

List of XXX = XXXPeer.doSelect(criteria);

Cheers,

Siegfried Goeschl

-----Original Message-----
From: Rie Nakajima [mailto:[EMAIL PROTECTED] 
Sent: Donnerstag, 29. Juli 2004 14:37
To: [EMAIL PROTECTED]
Subject: JOIN & result


Hello.

Though it is so easy question, but please help me out to complete my coding 
using Torque for the first time. (I'm using Version 3.1)

I am writing code in order to execute JOIN SQL statement with torque.

Here is the sample tables.
TableA has AUTHOR_ID, and AUTHOR_NAME.
TableB has AUTHOR_ID, BOOK_TITLE, and ISBN.

In order to make JOIN statement, I would write as follows;

Criteria crit = new Criteria(); crit.addJoin(TableAPeer.AUTHOR_ID, 
TableBPeer.AUTHOR_ID); List items = TableAPeer.doSelect(crit);

Here is my question;
After doing "doSelect" method, I would get item list which is filled with 
the all data from TableA and TableB.
How can I get data for each column, such as data of AUTHOR_NAME in TableA? (do I write 
like this?: item.getAUTHOR_NAME();???)

Basically I couldn't figure out how the selected values are stored in list 
object when using JOIN.

Again, I know it might be too easy to post this mailing list, but I will 
appreciate if any of you would kindly answer this question..

Thank you in advance.

_________________________________________________________________
Planning a family vacation? Check out the MSN Family Travel guide! 
http://dollar.msn.com


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to