Here you go

Wednesday, June 6, 2012

Function Which Provide AP Validation Invoice Status


Create Function Mentioned Below to get AP Invoice Validation Status.

For Example :
Invoice Validation Status 

Fully Applied
Unvalidated
Never Validated
Validated
Cancelled
Available
Needs Revalidation
Unpaid



CREATE OR REPLACE function APPS.TATA_AP_INVOICE_STATUS(P_Invoice_id Number)                          
return varchar2 is                                                          
V_STATUS varchar2(500);
                                             
begin                                                                  
                                                                     

        SELECT
                DECODE(AP_INVOICES_UTILITY_PKG.GET_APPROVAL_STATUS(AIA.INVOICE_ID,AIA.INVOICE_AMOUNT,AIA.PAYMENT_STATUS_FLAG,AIA.INVOICE_TYPE_LOOKUP_CODE),
                'FULL'            , 'Fully Applied',
                'NEVER APPROVED'  , 'Never Validated',
                'NEEDS REAPPROVAL', 'Needs Revalidation',
                'CANCELLED'       , 'Cancelled',
                'UNPAID'          , 'Unpaid',
                'AVAILABLE'       , 'Available',
                'UNAPPROVED'      , 'Unvalidated',
                'APPROVED'        , 'Validated',
                'PERMANENT'       , 'Permanent Prepayment',
                NULL)
                INTO  V_STATUS
        FROM  
                AP_INVOICES_ALL AIA
        WHERE   AIA.INVOICE_ID = P_INVOICE_ID;


return(V_STATUS);                                                      
                                                                     
EXCEPTION                                                              
  when no_data_found then                                                      
  return null;                                                              
                                                                     
end;

Extract Create Scripts of Objects




SELECT * FROM USER_SOURCE

OR

SELECT
        OBJ.OWNER,
        OBJ.OBJECT_TYPE,
        OBJ.OBJECT_NAME,
        DBMS_METADATA.GET_DDL(DECODE(OBJ.OBJECT_TYPE,'MATERIALIZED VIEW','MATERIALIZED_VIEW',OBJ.OBJECT_TYPE), OBJ.OBJECT_NAME , OBJ.OWNER )
FROM
        DBA_OBJECTS OBJ
WHERE
        OBJ.OBJECT_TYPE IN  (
                            'INDEX',
                            'MATERIALIZED VIEW',
                            'PACKAGE' ,
                            'FUNCTION',
                            'TABLE',
                            'TRIGGER',
                            'VIEW',
                            'SEQUENCE'
                            )

Best Download Links


Download Oracle Workflow Builder:

 


http://www.oracle.com/technetwork/database/options%20/winclient-101059.html


Key Words:

Download Workflow Builder Free

Download Workflow Builder Guide

Free Download Workflow Builder

Free Workflow Builder

Workflow Builder Download

 

FNDLOAD Download and Upload Concurrent Program and XML Template Script

FNDLOAD Create Concurrent Program and XML Template

Steps

1- Run the query ( Given Below ). 
              Query will provide you download and upload commands. It also enables you to Download  Template File. (i.e.RTF file)
2- Run environment file and Run download script on Source Node.
              This will create .ldt file and as well as log file.
3- Move .ldt file on Target Node and Run environment file and then Upload Script.
              This will upload you required file on Target Node. 

-------------------- Query for Generating FND LOAD Command -------------------------------


SELECT
    VV.USER_CONCURRENT_PROGRAM_NAME,
    FA.APPLICATION_NAME,
    VV.OUTPUT_FILE_TYPE REPORT_TYPE,
    FE.EXECUTABLE_NAME,
    VV.CREATION_DATE CREATION_DATE,
    -- Executable and Program --
    'FNDLOAD apps/' || NVL(:P_APPS_PWD,'apps') || ' 0 Y DOWNLOAD    $FND_TOP/patch/115/import/afcpprog.lct '|| VV.CONCURRENT_PROGRAM_NAME ||'.ldt PROGRAM APPLICATION_SHORT_NAME="' || FA.APPLICATION_SHORT_NAME || '" CONCURRENT_PROGRAM_NAME="' || VV.CONCURRENT_PROGRAM_NAME ||'"' DOWNLOAD_SCRIPT,
    'FNDLOAD apps/' || NVL(:P_APPS_PWD,'apps') || ' 0 Y UPLOAD      $FND_TOP/patch/115/import/afcpprog.lct '|| VV.CONCURRENT_PROGRAM_NAME ||'.ldt' UPLOAD_SCRIPT,
    -- Xml Template --
    XTMP.TEMPLATE_NAME,
    DECODE(VV.OUTPUT_FILE_TYPE,'XML',
    'FNDLOAD apps/' || NVL(:P_APPS_PWD,'apps') || ' 0 Y DOWNLOAD    $XDO_TOP/patch/115/import/xdotmpl.lct  "'|| FE.EXECUTABLE_NAME     ||'_XT.ldt" XDO_DS_DEFINITIONS APPLICATION_SHORT_NAME="' || XDEF.APPLICATION_SHORT_NAME || '"  DATA_SOURCE_CODE="'|| XDEF.DATA_SOURCE_CODE ||'" TMPL_APP_SHORT_NAME="' || XTMP.APPLICATION_SHORT_NAME ||'" TEMPLATE_CODE= "' || XTMP.TEMPLATE_CODE || '"'
    ) DOWNLOAD_TEMPLATE,
    DECODE(VV.OUTPUT_FILE_TYPE,'XML',
    'FNDLOAD apps/' || NVL(:P_APPS_PWD,'apps') || ' 0 Y UPLOAD      $XDO_TOP/patch/115/import/xdotmpl.lct  "'|| FE.EXECUTABLE_NAME     ||'_XT.ldt"'
        ) UPLOAD_TEMPLATE,
    (      
    SELECT
        XL.FILE_NAME    
    FROM      
        XDO_LOBS XL
    WHERE
        XL.XDO_FILE_TYPE            =   'RTF'
    AND XL.LOB_CODE                 =   XTMP.DATA_SOURCE_CODE  
    AND XL.APPLICATION_SHORT_NAME   =   XTMP.APPLICATION_SHORT_NAME
    )     RTF_FILE_NAME,
    (      
    SELECT
        XL.FILE_DATA    
    FROM      
        XDO_LOBS XL
    WHERE
        XL.XDO_FILE_TYPE            =   'RTF'
    AND XL.LOB_CODE                 =   XTMP.DATA_SOURCE_CODE  
    AND XL.APPLICATION_SHORT_NAME   =   XTMP.APPLICATION_SHORT_NAME
    )     CLICK_TO_DOWNLOAD                                                    
FROM
    FND_CONCURRENT_PROGRAMS_VL      VV,
    FND_APPLICATION_VL              FA,
    FND_EXECUTABLES                 FE,
    XDO_DS_DEFINITIONS_VL           XDEF,
    XDO_TEMPLATES_VL                XTMP
WHERE
    VV.CREATED_BY               =   1110
AND VV.APPLICATION_ID           =   660     ---    Order Management
AND VV.ENABLED_FLAG             =   'Y'
AND VV.EXECUTABLE_ID            =   FE.EXECUTABLE_ID
AND FA.APPLICATION_ID           =   VV.APPLICATION_ID
AND XDEF.DATA_SOURCE_CODE  (+)  =   FE.EXECUTABLE_NAME
AND XTMP.DATA_SOURCE_CODE  (+)  =   FE.EXECUTABLE_NAME
AND UPPER(VV.USER_CONCURRENT_PROGRAM_NAME) LIKE '%'||UPPER(:P_PROGRAM_NAME)||'%'