Eric -
You're correct in thinking that addSelectColumn will only work when
using doSelectVillageRecords as the ordinary variety of doSelect will
attempt to populate your OM objects and all its fields using an offset
method (rather than by field name). Thus, if selecting only one column, when
Torque's auto-generated code attempts to retrieve the second field, the
exception you're receiving will then be thrown.
Hope this helps.
- Justin
-----Original Message-----
From: Eric Emminger [mailto:[EMAIL PROTECTED]
Sent: Monday, March 31, 2003 10:09 AM
To: Turbine Torque Users List
Subject: what's the purpose of Criteria.addSelectColumn?
If you use addSelectColumn in a doSelect, you get a TorqueException. Is
addSelectColumn only intended for use in doSelectVillageRecords or am I
missing something?
For example,
Criteria crit = new Criteria();
crit.addSelectColumn(SomePeer.SOMEID);
List list = SomePeer.doSelect(crit);
will throw TorqueException, saying "Only 1 columns exist!"
Eric
---------------------------------------------------------------------
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]