Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JDBC connection using bean

 
Amol More
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi ranchers

i am trying to connect to the oracle database with the help of beans & jsp
i am not that familiar with and i am using netbeans as an interface
can you please help me with the procedure of connecting to the database

i have created a database in oracle of name emplyoee with first name ,last name and empno

this is my bean page


and this is my jsp page



ITS SHOWING ME AN ERROR in jsp page i have specifed it below
please help me with the procedure and rectify errors if any

<jsp:useBean id="db" scope="request" class="DbBean" /> //ERR CANNOT FIND SYMBOL

 
Deepak Bala
Bartender
Posts: 6663
5
Firefox Browser Linux MyEclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is the error ?
 
Campbell Ritchie
Sheriff
Posts: 48445
56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What error?
 
Amol More
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the error i am getting is cannot find symbol in the jsp page at the line 22
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34095
337
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I agree this is poor practice. That said, where is the code that sets DBBean in the request? It should be in a servlet somewhere. If it doesn't exist, that explains why the bean isn't in the request.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic