Working with Database Objects
All of the examples in this book use a database account named XMLBOOK that you’ll need to create to follow along and try out any code we discuss. In this section, we create an XMLBOOK user and explore JDeveloper 3.1’s features for working with database objects in the development environment.
Creating the XMLBOOK User to Run the Examples
To create the XMLBOOK user, connect to your Oracle database as a DBA account like SYS or SYSTEM using the SQL*Plus tool and issue the following commands:
SQL> CREATE USER xmlbook IDENTIFIED BY xmlbook; User created. SQL> GRANT connect, resource, query rewrite TO xmlbook; Grant succeeded.
Then try to connect as the new XMLBOOK user and try a simple SELECT statement by doing the following:
SQL> CONNECT xmlbook/xmlbook Connected SQL> SELECT sysdate FROM dual; SYSDATE --------- 23-APR-00
If this works, then you’re ready to go create a named connection for XMLBOOK inside the JDeveloper 3.1 environment.
Defining and Browsing Database Connections
JDeveloper 3.1 has a number of built-in features for working more easily with Oracle database objects. You can define any number of commonly used database connections that are then available for all workspaces and projects. After starting JDeveloper 3.1, you’ll notice a Connections folder at the top of the project navigator. Double-clicking on this folder or selecting Connections... from the right mouse button menu option on the folder brings up the JDeveloper Connection Manager dialog. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access