ARCHIVED: Use the sample account on the UITS Oracle database Oed1prd at IU
On this page:
- Overview
- View the contents of the sample account
- Copy tables from a sample account to your own account
Overview
At Indiana University, the UITS Oracle database Oed1prd has one sample user account, HRSAMPLE
. This account is set up so it cannot be modified, but can be accessed for reading or copying. The password for the HRSAMPLE
account is hrsample
.
View the contents of the sample account
To see a list of tables in the HRSAMPLE
account, log into the sample account HRSAMPLE
(username and password are both hrsample
) using the SQL*Plus Oracle Client tool. Alternatively, use SQL Developer to connect to the Oed1prd database and enter SQL statements in its SQL Worksheet; see ARCHIVED: Connect to the UITS Oracle database Oed1prd from the IUB and IUPUI STCs.
Once you have logged in, enter:
select * from cat;
To see a list of column definitions in a particular table, enter the command:
describe tablename;
Replace tablename
with the name of the table.
Copy tables from a sample account to your own account
If you have your own account on Oed1prd, you can practice SQL commands by copying tables from the sample account to your own account. To do so:
- Using the above procedure for listing the
HRSAMPLE
tables, determine the names of the tables in theHRSAMPLE
account that you would like to copy. - Query the contents of those tables from your own account by specifying the schema (account) name in the
SELECT
statement, as in the following example:select * from hrsample.tablename;
Substitute the name of the table for
tablename
. - Create a copy in your own account using the SQL in the following example:
create table tablename as select * from hrsample.tablename;
Substitute the name of the table for
tablename
(both places). - Verify that the table is now in your account by querying the catalog with the following command:
select * from cat;
- Verify that the table data copied over by querying the table with the following command:
select * from tablename;
Substitute the name of the table for
tablename
.
This is document anhn in the Knowledge Base.
Last modified on 2021-09-21 17:51:49.