Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL and Entity Beans

Status
Not open for further replies.

Stedo

Programmer
Sep 15, 2005
44
0
0
SE
hi,

I'm writing a J2EE app and I want to interface with a database. I've been looking at Entity beans and all is well. However what I want to do is simply execute an SQL statement and get a vector of strings back.

Do I have to use Entity Beans to do this? I have tried writing a finder function but on deployment I am told that finder functions can only return primary keys or collections of primary keys. Is there another way.

Thanks
Steve
 
I'm not sure about what a finder function is, but if you just want to connect to a database, you may not need a Bean, a JDBC connection can be enough.

Cheers,
Dian
 
hi,

If I don't connect to the database through a bean what do I connect to the database through?

Thanks
Steve
 
hi,

Okay, I figured it out, I can just use normal session beans with a local interface to connect to the database.

Thanks
Steve
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top