Could someone please help me with this. It has become a big problem.
Thanks,
Vidur
--
Hello,
I need help with defining a finder query. Here's the set up:
CMP DataWatchItem has a member String called name. Its primary key is
GUID guid (a homegrown globally unique identifier, that is
Serializable). DataWatchItem works fine -- it can be created, found,
and used.
CMP DataWatchLogItem, has a member DataWatchItem called source. Its
primary key is also a GUID. It also works fine.
I want to define a finder method on DataWatchLogItem, findByName (String
searchName). The logic is simple -- return a collection of
DataWatchLogItem such that source.name equals searchName. How do I
express this in orion-ejb-jar.xml?
I tried
<finder-method query="$source->getUsername() = $1">
It deploys but gives a runtime error
10/28/00 4:48 PM Error in bean DataWatchLogItem: Database Error
java.sql.SQLException: General error in statement [select
DataWatchLogItem.guid, DataWatchLogItem.source, DataWatchLogItem.runOn,
DataWatchLogItem.evaluatedValue, DataWatchLogItem.errorString from
DataWatchLogItem where
DataWatchLogItem.source->getUsername() = 'vdhanda']
When I use, <finder-method query="$source.username = $1">
On deployment, I get the error:
Auto-deploying lib (No previous deployment found)... Error compiling
file:/C:/dev/lib/: Unable to process query: source was not a
property/field mapped field (invalid '.' use) at column 16 in query
'?source.username = ?1'
Is expressing such a query possible in Orion?
Thanks,
Vidur
--
Vidur Dhanda
Active Solutions
tel: 617/566-1252
[EMAIL PROTECTED]
www.active-solutions-inc.com