Pages

Recently Viewed

Saturday, January 17, 2015

VO Extension without JDeveloper

VO Extension is tool (JDeveloper) dependent but can be done manually by using below steps.

Steps to extend VO:
Create new VO  xxxxx_StandardVO.xml by renaming the standard VO StandardVO.xml (from server).
Edit below sections of VO according your customization need.

<ViewObject>
Name = New VO Name
Extends = original VO Name with complete path
ComponentClass = NewVO associate file with complete path


<SQLQuery>
Update the SQL with new changes.


<ViewAttribute> - Not required If change is in where condition or existing SQL logic
If adding a new sql field,we need to add ViewAttributes for new field.

Example -
<ViewObject
   Name=" xxxxx_StandardVO "
   Extends="oracle.apps.application.subapplication.common.server. StandardVO"
   BindingStyle="OracleName"
   CustomQuery="true"
   ComponentClass="xxxxx.oracle.apps.application.subapplication.common.server.xxxxx_StandardVOImpl"
   UseGlueCode="false">

<ViewAttribute
      Name="NEWFIELD"
      IsUpdateable="false"
      IsPersistent="false"
      Precision="30"
      Type="java.lang.String"
      ColumnType="VARCHAR2"
      AliasName=" NEWFIELD "
      Expression=" NEWFIELD "
      SQLType="VARCHAR" >
      <DesignTime>
         <Attr Name="_OverrideAttr" Value="true" />
         <Attr Name="_DisplaySize" Value="30" />
      </DesignTime>
   </ViewAttribute>

Create associated java file xxxxx_StandardVOImpl.java
package xxxxx.oracle.apps.application.subapplication.common.server;
import oracle.apps.application.subapplication.common.server. StandardVOImpl;
public class xxxxx_StandardVOImpl extends StandardVOImpl {
    public xxxxx_StandardVOImpl() {
    }  }

Compile and generate class file (xxxxx_StandardVOImpl.class
Create a OAProject.jpx file
<?xml version='1.0' encoding='windows-1252' ?>
<!DOCTYPE JboProject SYSTEM "jbo_03_01.dtd">
<JboProject
   Name="OAProject"
   SeparateXMLFiles="true"
   PackageName="" >
   <DesignTime>
      <Attr Name="_ejbPackage" Value="false" />
      <Attr Name="_NamedConnection" Value="DBConnection1" />
      <Attr Name="_version" Value="10.1.3.41.57" />
      <Attr Name="_jprName" Value="OAProject.jpr" />
   </DesignTime>
   <Containee
      Name="server"
      FullName="oracle.apps.application.subapplication.common.server"
      ObjectType="JboPackage" >
   </Containee>
   <Containee
      Name="server"
      FullName="xxxxx.oracle.apps.application.subapplication.common.server"
      ObjectType="JboPackage" >
   </Containee>
   <Substitutes>
      <Substitute OldName ="oracle.apps.application.subapplication.common.server.StandardVO" NewName ="xxxxx.oracle.apps.application.subapplication.common.server.xxxxx_StandardVO" />
   </Substitutes>
</JboProject>

Create server.xml file
<?xml version='1.0' encoding='windows-1252' ?>
<!DOCTYPE JboPackage SYSTEM "jbo_03_01.dtd">

<JboPackage
   Name="server"
   SeparateXMLFiles="true"
   PackageName="xxxxx.oracle.apps.application.subapplication.common.server" >
   <DesignTime>
      <Attr Name="_ejbPackage" Value="false" />
      <Attr Name="_version" Value="10.1.3.41.57" />
   </DesignTime>
   <Containee
      Name="xxxxx_StandardVO"
      FullName="xxxxx.oracle.apps.application.subapplication.common.server.xxxxx_StandardVO"
      ObjectType="ViewObject" >
   </Containee>
</JboPackage>

Place all files at respective locations and run JPX Importer  

Friday, January 2, 2015

Print parametr in XML report without having XML tags

Oracle provides option to print input parameter directly in RTF without generating a XML tag for this. This can be done in below 2 steps,

Define the parameter reference: this can be done in two different ways
<?param@begin:P_PARAM?>
<xsl:param name="P_PARAM" xdofo:ctx="begin"/>
Print the report parameter value:
<?$P_PARAM?>


Example
CP Parameter Name
START_TIME
END_TIME

Invoke parameters on rtf
<?param@begin:START_TIME?>
<?param@begin:END_TIME?>

Create 2 form field (Placeholder) in RTF  with below values
<?$START_TIME?>
<?$END_TIME?>