DBA Data[Home] [Help]

PACKAGE BODY: APPS.PO_POXVDVOH_XMLP_PKG

Source


1 PACKAGE BODY PO_POXVDVOH_XMLP_PKG AS
2 /* $Header: POXVDVOHB.pls 120.1 2007/12/25 12:41:39 krreddy noship $ */
3 
4 function BeforeReport return boolean is
5 begin
6 
7 declare
8 l_sort     po_lookup_codes.displayed_field%type ;
9 begin
10 
11 if P_orderby is not null then
12 
13     select displayed_field
14     into l_sort
15     from po_lookup_codes
16     where lookup_code = P_orderby
17     and lookup_type = 'SRS ORDER BY';
18 
19     P_orderby_displayed := l_sort ;
20 
21 else
22 
23     P_orderby_displayed := '' ;
24 
25 end if;
26 
27 
28 
29 /*SRW.USER_EXIT('FND SRWINIT');*/null;
30 
31 RETURN TRUE;
32 
33 end;  return (TRUE);
34 end;
35 
36 function orderby_clauseFormula return VARCHAR2 is
37 begin
38 
39 if    P_orderby = 'VENDOR' then
40       return('pov.vendor_name');
41 elsif P_orderby = 'PO NUMBER' then
42       return('decode(psp1.manual_po_num_type, ''NUMERIC'', null, poh.segment1)
43 ,        decode(psp1.manual_po_num_type,''NUMERIC'',decode(rtrim(poh.segment1,''0123456789''),null,to_number(poh.segment1),-1),
44                      null)');
45 end if;
46 RETURN NULL; end;
47 
48 function AfterReport return boolean is
49 begin
50   /*SRW.USER_EXIT('FND SRWEXIT');*/null;
51 
52   return (TRUE);
53 end;
54 
55 --Functions to refer Oracle report placeholders--
56 
57 END PO_POXVDVOH_XMLP_PKG ;
58