Thursday, May 14, 2015

adop phase=cleanup is Failing with below error

adop phase=cleanup is Failing with below error


Calling cleanup in STANDARD mode...
    Log: @ADZDSHOWLOG.sql "2015/05/14 19:21:47"
    [ERROR]     Failed to execute SQL statement :
       begin
        execute immediate 'alter session set DDL_LOCK_TIMEOUT = 600';
        ad_zd.cleanup('STANDARD');
      end;

    [ERROR]     Error Message :
    [UNEXPECTED]Error occurred while calling cleanup plsql API
    [UNEXPECTED]Cleanup phase completed with errors/warnings. Please check logfiles


[STATEMENT] Please run adopscanlog utility, using the command

"adopscanlog -latest=yes"

to get the list of the log files along with snippet of the error message corresponding to each log file.

adop exiting with status = 1 (Fail)

SQL> select count(*) from dba_obJects where status='INVALID' AND object_name like 'AD%';


  COUNT(*)
----------
         1

SQL> SQL> select object_name from dba_obJects where status='INVALID' AND object_name like 'AD%';

OBJECT_NAME
--------------------------------------------------------------------------------
AD_ZD_TABLE

SQL> alter package apps.AD_ZD_TABLE compile;

Warning: Package altered with compilation errors.

SQL> alter package apps.AD_ZD_TABLE compile body;

Warning: Package Body altered with compilation errors.

Fix#
SQL> @/ad_TXK_patches_delta_6/19197270/admin/adgrants.sql APPS
Connected.

then compile the object.
SQL> alter package apps.AD_ZD_TABLE compile;

Package altered.

SQL> alter package apps.AD_ZD_TABLE compile body;

Package body altered.

Materialized Views become Views after upgraded to 12.2


"On an editioned database, you can no longer create a materialized view directly" as you did in previous releases.
In order to work around this restriction the Oracle E-Business Suite Online Patching solution implements a new
Effectively-Editioned Materialized View compound object. The developer-specified query is stored in an ordinary view,
called the Logical View. The Materialized View is then generated from the Logical View, using a new database feature that translates the
logical query into an equivalent, edition-legal "implementation query".

Therefore, what you see after the upgrade, that your Materialized view becomes a regular view is expected. So now, you will need to generate
the Materialized view using the new db feature already mentioned. Please go to section Section 1.4.2.5: Materialized Views of note
"Developing and Deploying Customizations in Oracle E-Business Suite Release 12.2 ( Doc ID 1577661.1 )" that will describe how to make your
logical view become a Materialized view.


The Online Patching Database Compliance Checker Report
This utility reports all violations to the Online Patching development standards for database objects.
You must fix any object listed in this report that is part of your custom code. If you do not fix the violations,
then you cannot use the online patching infrastructure to patch the objects listed in this report.

Check for violations of online patching database standards by running the Online Patching Database Compliance Checker with the following command

sqlplus <APPS username> @$AD_TOP/sql/ADZDDBCC.sql By running this script it will generate a report "adzddbcc.lst" which custom objects viaolating online patching standards.

This report has precise information why the object can not be re-defined. Please review and redefine the object according to the Edition based database where as objects should not reference editioned objects.

Wednesday, May 13, 2015

Applying R12.TXK.C.Delta.6 patch 19330775 failed with following error



Reading driver file (up to 50000000 bytes).
  Patch file system freespace: 91.41 GB
Validating system setup...
  Node registry is valid.
  Application services are down.
  [ERROR] Failed to execute SQL statement :
  declare
  l_msg varchar2(4000);
 begin
  ad_zd_adop.adop_database_validations(l_msg);
  dbms_output.put_line(l_msg);
 end;
  [ERROR] Error Message :
  [UNEXPECTED]Error occurred while performing database validations
[STATEMENT] Please run adopscanlog utility, using the command
"adopscanlog -latest=yes"
to get the list of the log files along with snippet of the error message corresponding to each log file.
adop exiting with status = 1 (Fail)


1. Use the following query to see whether it provides output:
select value from v$parameter where name='_system_trig_enabled'; 
2. If no rows are selected or set as false, then:
Edit the database initialization parameter file to set the value of '_system_trig_enabled' parameter to TRUE as documented in: Note 396009.1.  and retry to apply the patch.
OR
3. Check and correct the node_name in the table applsys.TXK_TCC_RESULTS if it s not showing in the correct case (upper/lower) and retry to apply the patch.
4. Additionally if the above scenarios does not match the case, then run the following (connect  as apps schema in sqlplus) and check the results for more information about the error,
Run the failing sql standalone in sqlplus as apps user as following,
set serveroutput on;
declare
   l_msg varchar2(4000);
 begin
   ad_zd_adop.adop_database_validations(l_msg);
   dbms_output.put_line(l_msg);
 end;
/


Our cases in which this failure could happen:
-> If package AD_ZD_PREP is invalid. This might happen when latest adgrants.sql is not run or some database patches are missing or post install steps of database patches are not run
-> AD_ZD_ADOP or any of the other related AD packages are invalid.


Fix# Run Higher version of adgrants.sql APPS
Our Case the higher version of script from "R12.AD.C.Delta.6 (Patch 19197270)"
19197270/admin/adgrants.sql APPS

And then Compile#
SQL> alter package apps.AD_ZD_PREP compile;

Package altered.


Doc Id# 1993838.1

Good Luck!!



Monday, May 11, 2015

Script To Check The Techstack Component Versions (Forms, Http Server, JDK, Framework, Database, etc)


On Application Tier

$$ADPERLPRG $FND_TOP/patch/115/bin/TXKScript.pl \
> -script=$FND_TOP/patch/115/bin/txkInventory.pl -txktop=$APPLTMP -contextfile=$CONTEXT_FILE -appspass=appsprj4 -outfile=$APPLTMP/Report_App_Inventory.html

Report_App_Inventory.html generated successfully.


Note: 
- Run the above command in single line 
- Remove the '\' after each parameter while you run this command in a single line
- Supply the apps user password as is applicable for parameter "-appspass"

On Db Tier

$ADPERLPRG $ORACLE_HOME/appsutil/bin/TXKScript.pl
-script=$ORACLE_HOME/appsutil/bin/txkInventory.pl -txktop=$ORACLE_HOME/appsutil/temp
-contextfile=$CONTEXT_FILE
-appspass=apps
-outfile=$ORACLE_HOME/appsutil/temp/Report_DB_Inventory.html
Note: - Run the above command in single line
- Supply the apps user password as is applicable for parameter "-appspass"
Doc ID 601736.1