Ok..still new to this EJB thing. Got my entity bean stored in the hSQL
table, I am able to iterate over the Collection returned by the findAll()
method. Now the question is, how do I find my one object? More specifically,
I created a simple entity that has a name (primary key), login, and
password. I added a couple of items to the table. Now, like I said I can see
all the items added..so they are being stored. Now I want to search for the
login and password that someone types in. I see the findByPrimaryKey()
method, which would find one item via the primary key of name. But how do I
search by the login and password for one item to see if it exists, or by
those fields to get say..a series of items with the same criteria (for
example, all rows that contain the same login name..assuming its not a not
null column which if I am correct, CMP only makes NOT NULL out of primary
keys).

Thanks.


Reply via email to