Database Access in YourCo

The YourCo Web site contains many examples of database access. You can find examples that query, insert, update, and delete data. All of the YourCo data are loaded into relational tables in the SAMPLE database. And, all of the servlets that access this data were created with the WebSphere Studio database wizard.

You can look up employees in the YourCo White Pages directory, even if you have not logged in yet. But, you must log in as a YourCo employee to go to the rest of the database examples:

  1. From the Home page, click Employee Center.
  2. Log in as a valid YourCo employee.
  3. From the Employee Center page, go to:

White pages: You can search for YourCo employees (query) by their last name, by their department, or by their position.

  • (locations are relative to <was_root>/hosts/default_host)
  • Look for the Java and SQL files used to query the EMPLOYEE table in WSsamples_app/servlets/WebSphereSamples/YourCo/Search.
  • Look for the input and result pages in WSsamples_app/web/YourCo/Search.

Let's Meet: You can find all the conference rooms (query) that are scheduled for meetings by the date, room, or person who has reserved it. You can also browse to see the entire meeting room schedule. If a room is not reserved, click the Reserve button to reserve it for yourself.

  • (locations are relative to <was_root>/hosts/default_host)
  • Look for the Java and SQL files used to query and maintain the meeting room databases in WSsamples_app/servlets/WebSphereSamples/YourCo/Meeting.
  • Look for the input and result pages in WSsamples_app/web/YourCo/Meeting.

Help Wanted: You can find open job positions (query) at YourCo. If you are a manager, your can post a new position (insert), change the criteria of a posted job (update), or cancel one when you fill it (delete).

  • (locations are relative to <was_root>/hosts/default_host)
  • Look for the Java and SQL files used to query the JOBS database in WSsamples_app/servlets/WebSphereSamples/YourCo/Jobs.
  • Look for the input and result pages in WSsamples_app/web/YourCo/Jobs.