Skip to Content
Author's profile photo Former Member

ORA-00942 and BR0310E Error – Solution

Hello All;

After a successful system refresh you may want to start taking backups of this system, but you may face errors, and in my case I had the following errors:

————————————————————————————————————————————————————

BR0310E Connect to database instance SID failed

BR0301E SQL error -942 at location BrDbConnect-6, SQL statement:

‘SELECT NAME, DBID, NVL(RESETLOGS_CHANGE#, 0), NVL(TO_NUMBER(TO_CHAR(RESETLOGS_T

IME, ‘YYYYMMDDHH24MISS’)), 0), NVL(TO_NUMBER(TO_CHAR(CREATED, ‘YYYYMMDDHH24MISS’

)), 0) FROM V$DATABASE’

ORA-00942: table or view does not exist

BR0310E Connect to database instance SID failed

————————————————————————————————————————————————————–

I found out that after a system refresh, or system upgrade we need to re-grant authorizations, and permissions to brtools, with creating SAPDBA role.

To fix the errors I did the following:

1- Copy the attached sql script attached to sap note 134592. My oracle version is 11.g so I copied sapdba_role_ora11.SAR as you can see below:

Capture.PNG

2- This sql script is a SAR file which is a compressed file, and for that we need to extract it using SAPCAR which can downloaded from SAP Marketplace under service.sap.com –> support portal –> software downloads –> support packages and patches –> brows our download catalogue –> additional components –> SAPCAR

Capture.PNG

3- Under the same directory put both SAPCAR, and sapdba_role_ora11.SAR , and extract the script using the command “SAPCAR -xvf *” as below:

Capture.PNG

4- Run the command  “sqlplus /nolog @sapdba_role <SAPSCHEMA_ID>”

The ID of my schema is SR3 so the command in my case will sqlplus /nolog @sapdba_role SR3

Note: To know the schema ID in your case run the transaction DB02 in your SAP system –> tablespaces –> overview –> check the first tablename it will be PSAP then directly your schema ID. In my case it is PSAPSR3 the default name of SAP ABAP schema

Capture.PNG

5- To make sure that your command was issued successfully, open the new generated file on the same location where you run the command. The file is called sapdba_role.log at the end of this file you should see “PL/SQL procedure successfully completed” as below:

Capture.PNG

Now if you go, and run DB13 you will be able to take backups as usual as usual as before the system restore, or the system upgrade.

Best Regards

~Amal Aloun

Assigned Tags

      1 Comment
      You must be Logged on to comment or reply to a post.
      Author's profile photo Varun Kumar Pathapati
      Varun Kumar Pathapati

      Hi Amal,

      Very resourceful stuff !!!

      Regards,

      varun Kumar Pathapati.