Unable to connect to Oracle database ORA-00942: table or view does not exist
Symptoms
Unable to migrate to Oracle database.
The following appears in the atlassian-fisheye-<date>.log
:
2013-05-09 11:10:15,136 ERROR - Unable to connect to Oracle database jdbc:oracle:thin:@HostnameXXX:1635:dbnameXXX: java.sql.SQLException: ORA-00942: table or view does not exist
Diagnosis
Try connecting to your Oracle database with a database client such as SQLDeveloper or DBVisualizer using the login credentials of your Fisheye/Crucible database user.
Once you are connected, try to manually create a table in the database.
create table t (
a number,
b varchar2(10)
);
If you are thrown a permission error, then your Fisheye/Crucible database user does not have sufficient privileges to create tables in the database. After failing to create tables Fisheye/Crucible tries to insert data into the tables and throws the above error.
Cause
The Fisheye/Crucible database user does not have sufficient privileges to create tables in database.
Resolution
The Fisheye/Crucible database user should have at least the connect
and resource
privilege to the database. If you are unsure how to grant this permission, talk to your oracle DBA.
In this particular case the resource
role is missing: this is the role that grants the ability for users to create objects in their own schema.
Generally, these are the permissions needed, as stated in the following command:
grant connect, resource, create table to <database_user_name>;