Showing posts with label BI Pub. Show all posts
Showing posts with label BI Pub. Show all posts

Nov 30, 2010

What is XML Tag Generation? and How to Generate XML Tag ?

 How to Generate  XML Tag ?

CREATE OR REPLACE PACKAGE nilesh_XML AS

PROCEDURE put_xml_tags(i_tag_type_flag IN VARCHAR2
                      ,i_tag_name      IN VARCHAR2 DEFAULT NULL
                      );

PROCEDURE put_xml_data ( i_xml_tags IN VARCHAR2
                       , i_output  IN VARCHAR2
                       )
PROCEDURE XX_XML (i_employee_number IN VARCHAR2);
            
END;

CREATE OR REPLACE PACKAGE nilesh_XML AS

PROCEDURE put_xml_tags(i_tag_type_flag IN VARCHAR2
                      ,i_tag_name      IN VARCHAR2 DEFAULT NULL
                      )
IS
--
  l_strng VARCHAR2(32376);
--
BEGIN
--
  CASE
  WHEN i_tag_type_flag = 'S' THEN
--
      l_strng := '';
      FND_FILE.PUT_LINE(FND_FILE.OUTPUT,l_strng||CHR(10));
--
      l_strng := '';
      FND_FILE.PUT_LINE(FND_FILE.OUTPUT,l_strng||CHR(10));
--
      l_strng := ''|| USERENV('LANG') ||'';
      FND_FILE.PUT_LINE(FND_FILE.OUTPUT,l_strng||CHR(10));
--
      l_strng := ''|| TO_CHAR(SYSDATE,'DD-MON-RRRR') ||'';
      FND_FILE.PUT_LINE(FND_FILE.OUTPUT,l_strng||CHR(10));
--
    WHEN i_tag_type_flag = 'E' THEN
--
        l_strng := '
';
      FND_FILE.PUT_LINE(FND_FILE.OUTPUT,l_strng||CHR(10));
--
    WHEN i_tag_type_flag = 'G' THEN
--
      l_strng := '<'||i_tag_name||'>';
      FND_FILE.PUT_LINE(FND_FILE.OUTPUT,l_strng||CHR(10));
--
  END CASE;
--
EXCEPTION
  WHEN OTHERS THEN
    FND_FILE.PUT_LINE(FND_FILE.LOG,'PERC1428-put_xml_tags Function Error '||SQLERRM);
--
END put_xml_tags;
--
PROCEDURE put_xml_data ( i_xml_tags IN VARCHAR2
                       , i_output  IN VARCHAR2
                       )
IS
  i_occ       NUMBER(2):=1;
  l_xml_tag   VARCHAR2(32767);
  l_output    VARCHAR2(32767) ;
  l_strng     VARCHAR2(32767);
 BEGIN
--
    WHILE (INSTR(i_xml_tags,'#',1,i_occ)!=0) LOOP
      BEGIN
        SELECT  SUBSTR(i_xml_tags,DECODE(i_occ,1,1,INSTR(i_xml_tags,'#',1,i_occ-1)+1),INSTR(i_xml_tags,'#',1,i_occ)-DECODE(i_occ,1,1,INSTR(i_xml_tags,'#',1,i_occ-1)+1))
        INTO l_xml_tag
        FROM dual;
    EXCEPTION
      WHEN OTHERS THEN
          l_xml_tag :='END';
    END;
--
    BEGIN
       SELECT  SUBSTR(i_output,DECODE(i_occ,1,1,INSTR(i_output,'#',1,i_occ-1)+1),INSTR(i_output,'#',1,i_occ)-DECODE(i_occ,1,1,INSTR(i_output,'#',1,i_occ-1)+1))
       INTO l_output
       FROM dual;
    EXCEPTION
       WHEN OTHERS THEN
         l_output :='';
    END;
--
      l_strng:= ('<'||l_xml_tag||'>'||''||'');
      FND_FILE.PUT_LINE(FND_FILE.OUTPUT,l_strng||CHR(10));
--
      i_occ := i_occ+1;
--
   END LOOP;
   --
 EXCEPTION
   WHEN OTHERS THEN
      FND_FILE.PUT_LINE(FND_FILE.LOG,'PERC1428- put_xml_data Function Error '||SQLERRM);
END put_xml_data;

PROCEDURE XX_XML( o_errbuf             OUT VARCHAR2 -- Error Message
                , o_retcode            OUT VARCHAR2 -- Error Code
                , i_employee_number    IN  VARCHAR2
AS
 l_xml_tags VARCHAR2(32376);
 l_xml_data VARCHAR2(32376);
 CURSOR c_emp_info ( i_employee_number  IN NUMBER
                   )
 IS
 Select first_name, last_name, full_name, employee_number from per_all_people_f where employee_number=i_employee_number;

BEGIN
    put_xml_tags('S');   
    put_xml_tags('G','G_EMP_INFO');
    BEGIN
      FOR r_emp_info IN c_emp_info(i_employee_number)
      LOOP
         l_xml_tags := 'LAST_NAME#FIRST_NAME#FULL_NAME#EMPLOYEE_NUMBER#';
         l_xml_data := r_emp_info.last_name                     || '#' ||
                       r_emp_info.first_name                    || '#' ||
                       r_emp_info.full_name                     || '#' ||
               r_emp_info.employee_number               || '#' ;
         put_xml_data(l_xml_tags,l_xml_data);
       END LOOP;
    put_xml_tags('G','/G_EMP_INFO');
    put_xml_tags('E');
EXCEPTION
  WHEN OTHERS THEN
       FND_FILE.PUT_LINE(FND_FILE.LOG,'Error occured IN PERC1435' || SQLERRM);
END XX_XML;

END nilesh_XML;
/

Mar 29, 2010

How to Develop XML Publisher Report (XMLP) or BI Publisher Reports?

Training  of XML Publisher Report (XMLP) or BI Publisher Reports:

How to Develop XML Publisher Report (XMLP) or BI Publisher Reports?

hey Guys Now adays BI Publisher is in Boom technology formally it know as XMLP means XML Publisher.
We can develop this by using following steps:

1)Develop the Report(.rdf) Only DataModel

2)Save the report and Compoile and Generate the data in .xml
           Format File=>Generate to File => XML

3)Open the Ms-Word document Design the Layout include the follwing Tool Bar options called Form and Templete builder

4)Define the Table and Specify the Titles and Labels whatever we would like to print

5)Include 'Text Form Field' Double CLick => Add Help Text button enter the following syntax : Here G_USER_ID is Group name from .rdf Data Model Note: It means Indirectley Repeating Frame starting

6)Define the Fields which we would like to display Include 'Text Form Field' Double CLick => Add Help Text button enter the following syntax ?
Note: Define all the fields like this

7)We have to close the Repeating Frame (For each Loop) Include 'Text Form Field' Double CLick => Add Help Text button enter the following syntax

8)Save the document in .rtf(Rich Text File format)

9)Load the .xml file data and generate the Output in pdf Format Data=>Load XMl Data=>Load the .xml File=>Once Data is Loaded succesfully

10)Generate the Preview as per this Preview=>PDF

Registering in Apps

1)Develop the .rdf file and .rtf file

2)Register both .rdf and .rtf file


.rdf File Registration

1)Move the .rdf file into CUS_TOP\11.5.0\Reports\US

2)Create Execuiteable

Concurrent Program Output = XML

Request Group

Responsibility

User

SRS

3)Copy the Concurrent Program Short name .rtf File


RTF Registration:

1)Goto the XML Publisher Administrator Responsibility

2) Creation of Data Defination
Select Data Definations form Enter Data Defination

Name = Enter Any Name

Code = Concurrent Program Short Name

Application = Any application

startdate = Current Date

3)Copy the DataDefination name we have to add this to the Templete

4)Creation of Template form

Open the Templete Form

Enter Templete Name : Any Name

DataDefination : enter data defination whatever we have created

Code : Concurrent Program Short Name

Type : rtf

application : any Application

File : Upload the .rtf file

Laguage : English

Territory : United States

5)Select Apply button

After register the .rtf file submit concurrent Program from SRS window system will automatically pick the .rtf file and generates the Output.

If we want to customze the .rtf file we have to download by using templete , Customize thenupload the .rtf templeteme, a.sal, b.sal, b.empno, b.ename from emp a, emp b where a.mgr=b.empno and a.sal>b.sal



Oracle E-Business Suite Development & Extensibility Handbook (Osborne ORACLE Press Series)

Mar 26, 2010

setting the Password for PDF File sent through XML Publisher

setting the Password for PDF File sent through XML Publisher

Open the rtf for which you want to set password and do the following things

1) Open the .rtf
2) Go to File - > Properties
Create a new custom property
a) Name : xdo-pdf-open-password
Type : text
Value : Either Hard Code the value / or get the value for xml data
b) Name : xdo-pdf-security
Type : text
Value : true

Note : property name should always start with xdo- .



Cracking the Oracle Apps DBA Interview: 325 Frequently Asked Questions

OraApps Search

Custom Search

Search This Blog