Solved

oracle report

Posted on 2004-08-13
4
2,560 Views
Last Modified: 2013-12-12
Is there a way to generate oracle report in pdf format
0
Comment
Question by:alialyosofy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 7

Accepted Solution

by:
BobMc earned 250 total points
ID: 11797886
With Oracle Reports, you need to set the REPFORMAT to PDF.
Heres an example from Oracle :

Problem Description:
====================
Using RUN_PRODUCT to start a report from a form on the web.
IF DESTYPE is set to SCREEN or PREVIEW the format is specified by the
FORMS60_REPFORMAT environment variable.
DESFORMAT will be ignored if it is used to change the format
of the report output.
Problem Explanation:
====================
The following example describes the problem
Registry:
---------
TO MODIFY THE REGISTRY:
1) click on START, then RUN
2) type REGEDT32
3) click on HKEY_LOCAL_MACHINE
4) click on SOFTWARE
5) click on ORACLE
6) under ORACLE to the right frame look for FORMS60_REPFORMAT
7) If you don't have it, click on EDIT, NEW, STRING VALUE
8) You will now see a NEW VALUE #1 highlighted...type in FORMS60_REPFORMAT
9) Click once on it to highlight it and RIGHT CLICK and MODIFY
10) Edit VALUE and type in 'PDF' or 'HTML'....no quotes...just PDF or HTML
Forms Trigger:
--------------
Note: DESTYPE = SCREEN
DESFORMAT = PDF
FORMS60_REPFORMAT = HTML
DECLARE
pl_id Paramlist;
v_Show_Report_Name VARCHAR2(50);
BEGIN
pl_id := GET_PARAMETER_LIST('tmpdata');
If NOT Id_Null(pl_id) THEN
Destroy_Parameter_List(pl_id);
END IF;
pl_id := Create_Parameter_List('tmpdata');
Add_Parameter(pl_id,'PARAMFORM', TEXT_PARAMETER, 'YES');
Add_Parameter(pl_id,'DESTYPE',TEXT_PARAMETER,'SCREEN');
Add_Parameter(pl_id,'DESFORMAT',TEXT_PARAMETER,'PDF');
Add_Parameter(pl_id,'ORIENTATION',TEXT_PARAMETER,'LANDSCAPE');
RUN_PRODUCT(REPORTS,'c:\orant\forms60\emp',SYNCHRONOUS,RUNTIME,FILESYSTEM,pl_id,'');
Destroy_Parameter_List(pl_id);
END;
PROBLEM:
--------
The output will be HTML not PDF
Solution Description:
=====================
A workaround is to set DESTYPE to FILE instead of SCREEN
and use WEB.SHOW_DOCUMENT to display the output file produced.
The above example should be modified as follows:
Registry:
---------
FORMS60_REPFORMAT = HTML
Forms Trigger:
--------------
Note: DESTYPE = FILE
DESNAME = c:\webforms\test.pdf
DECLARE
pl_id Paramlist;
v_Show_Report_Name VARCHAR2(50);
BEGIN
pl_id := GET_PARAMETER_LIST('tmpdata');
If NOT Id_Null(pl_id) THEN
Destroy_Parameter_List(pl_id);
END IF;
pl_id := Create_Parameter_List('tmpdata');
Add_Parameter(pl_id, 'PARAMFORM', TEXT_PARAMETER, 'YES');
Add_Parameter(pl_id,'DESTYPE',TEXT_PARAMETER,'FILE');
Add_Parameter(pl_id,'DESFORMAT',TEXT_PARAMETER,'PDF');
Add_Parameter(pl_id,'DESNAME',TEXT_PARAMETER,'c:\webforms\test.pdf');
Add_Parameter(pl_id,'ORIENTATION',TEXT_PARAMETER,'LANDSCAPE');
RUN_PRODUCT(REPORTS,'c:\orant\forms60\emp',SYNCHRONOUS,RUNTIME,FILESYSTEM,pl_id,'');
Web.Show_Document('http://<server_name>/<virtual_path>/test.pdf','_SELF');
Destroy_Parameter_List(pl_id);
END;
Solution Explanation:
=====================
DESNAME is hard coding the path as well as the output file name in this example.
WEB.SHOW_DOCUMENT <virtual_path> is set in the web server and should point to
the location of the output file.
0
 
LVL 14

Assisted Solution

by:leoahmad
leoahmad earned 250 total points
ID: 11797948
yes it is easy
Do the following steps
make a report in the report builder then

In the Object navigator goto System parameters
double desformat and write initial value pdf
now double click the desname and write the path where file going to store like c:\report.pdf ( this inclueded the file name) in the initial value
then double click the destype and select the file from list
now run the report
it ask for print click  on print button and report save in pdf format.

LeoAhmad
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
This video shows syntax for various backup options while discussing how the different basic backup types work.  It explains how to take full backups, incremental level 0 backups, incremental level 1 backups in both differential and cumulative mode a…
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question