How to generate Excel files in Oracle Reports

Hi,
I've already built a JSP using oracle reports and Deploy on the report service. I also add a button to the left of the JSP.The next thing I want to do is:when user click on the button, the system will prompt a excel file contains the same content as the JSP file.
Can anybody teach me how to do? Thanks very much

Hi Ni,
It may not be possible to see the output of the SAME report in Excel as well. You will have to design another report which can open in Excel. You can follow this demo:
http://otn.oracle.com/products/reports/htdocs/getstart/demonstrations/excel/index.html
Then you can add an action to your button so that it opens the new report in a new browser window. This new browser window will open MS Excel and show the report inside Excel.
The reason that you can't output the SAME report in HTML as well as MS Excel is because we use page contentType to specify the application that the browser should open the document in (the application can be MS Word, MS Excel, etc). For example,
<%@ page contentType="application/vnd.ms-excel" %>
But we can only specify one contentType for a JSP, so the report can either be viewed as HTML or inside MS Excel.
Navneet.

Similar Messages

  • How to generate excel file in oracle forms 10g on client machine

    dear Sir,
    I am using just file server(installed 10g dev suite) not a oracle application server,
    I am running my application from another machine ,it running fine i want to generate excel report on client machine
    presently i m using OLE2 for fetching the data in excel , it is working fine but it generates the excel file on file server machine and i want get the output excel on the client machine. aftre OLE2 i m using CLIENT_OLE2 with webutil (instead of OLE2) its get compile successfully but during runtime it give error "oracle.forms.webutil.ole.OleFunctions bean not "found.CLIENT_OLE2.create_obj will not work"
    *so please tell me without oracle application server is this possible or not .*

    your webutil on server side is not configured
    you need to re install the webutil jacob.dll files etc. then it will work fine..
    you can also generate excel file using reports to change the destination format in SPREADSHEET

  • Generated pdf file from oracle reports show bad characters

    Hello all,
    Iam fighting with a problem with generated pdf file from oracle reports which show some bad characters. I was searching for some information but it didnt help...
    I have Oracle Database 11g R2 (or 10g R2) on Oracle Linux or Windows, Oracle forms and reports 6i (i know that is very old and not supported with 11gr2 but we are in this scenario).
    NLS parameters are set like this
    server:
    NLS_CHARACTERSET EE8MSWIN1250
    NLS_TERRITORY AMERICA
    NLS_LANGUAGE AMERICAN
    client:
    NLS_CHARACTERSET EE8MSWIN1250
    NLS_TERRITORY SLOVAK
    NLS_LANGUAGE SLOVAKIA
    When I run Oracle Reports it show perfect in display and when I try to print them, they are all good with good characters, but when I try to generate pdf file, some characters like č,š,ľ are not displaying corectly... This happen only when try to generate to pdf...
    I try to work with uifont.ali on client side but without any result. Fonts for reports were installed on client and server side... Can someone help me with this problem? Thank you very much for every advice.
    Martin

    Hi Sergiusz,
    Thank you for your reply. I look at what you wrote and try to make some test...
    1) For first I download FontForge, which can generate type1 font from true type. So I open FontForge and open my Arial.ttf font and use "Generate Fonts" to save my Arial.ttf font to pfb and pfm (whoch are need to set in uifont.ali). I have to change encoding, because my font has 2byte encoding so I reecondode the font from ISO10646-1 to ISO8859-2 and generate to pfb.
    2) Then I navigate REPORTS_PATH from regedit to my *.pfm and *.pfb files.
    3) I add these lines to end of my uifont.ali
    [ PDF:Embed ]
    Arial = "Arial.pfm Arial.pfb"
    ArialNarrow = "ArialNarrow.pfm ArialNarrow.pfb"
    4) Then I generate my report but nothing change... I check "Font used" in my pdf file, but there were not my fonts embedded I guess..
    I also try PDF:Subset, but it doesnt change anything... I try PDF aliasing to see if my uifont is working - this work very well, but I dont need to change font...
    Any other advice? Thank you so much to everyone!
    Martin

  • How to generate Excle file for a report runningin a Batch job

    Hello All,
    Can we generate Excle file for a report running in a Batch job.
    Kindly send reply to     [email protected]
    Thanks in Advance.
    Cheers,
    Sundeep

    Dear Sundeep,
    I'm providing you with the following piece of code ... Its working fine for me ... hopefully it suits your requirement ...
    D A T A D E C L A R A T I O N *
    TYPES: BEGIN OF TY_EXCEL,
    CELL_01(80) TYPE C,
    CELL_02(80) TYPE C,
    CELL_03(80) TYPE C,
    CELL_04(80) TYPE C,
    CELL_05(80) TYPE C,
    CELL_06(80) TYPE C,
    CELL_07(80) TYPE C,
    CELL_08(80) TYPE C,
    CELL_09(80) TYPE C,
    CELL_10(80) TYPE C,
    END OF TY_EXCEL.
    DATA: IT_EXCEL TYPE STANDARD TABLE OF TY_EXCEL,
    WA_EXCEL TYPE TY_EXCEL..
    E V E N T : S T A R T - O F - S E L E C T I O N *
    START-OF-SELECTION.
    Here you populate the Internal Table.
    Display - Top of the Page.
    PERFORM DISPLAY_TOP_OF_PAGE.
    E V E N T : E N D - O F - S E L E C T I O N *
    END-OF-SELECTION.
    SET PF-STATUS 'GUI_STATUS'.
    E V E N T : A T U S E R - C O M M AN D *
    AT USER-COMMAND.
    CASE SY-UCOMM.
    WHEN 'EXPORT'.
    Exporting the report data to Excel.
    PERFORM EXPORT_TO_EXCEL.
    ENDCASE.
    *& Form DISPLAY_TOP_OF_PAGE
    text
    --> p1 text
    <-- p2 text
    FORM DISPLAY_TOP_OF_PAGE .
    SKIP.
    WRITE: /05(128) SY-ULINE,
    /05 SY-VLINE,
    06(127) 'O R I C A'
    CENTERED COLOR 1,
    132 SY-VLINE.
    WRITE: /05(128) SY-ULINE,
    /05 SY-VLINE,
    06(127) 'Shift Asset Depreciation - Period/Year-wise Report.'
    CENTERED COLOR 4 INTENSIFIED OFF,
    132 SY-VLINE.
    WRITE: /05(128) SY-ULINE.
    E X C E L O P E R A T I O N
    CLEAR: IT_EXCEL[],
    WA_EXCEL.
    PERFORM APPEND_BLANK_LINE USING 1.
    WA_EXCEL-cell_02 = ' XYZ Ltd. '.
    APPEND WA_EXCEL TO IT_EXCEL.
    CLEAR: WA_EXCEL.
    WA_EXCEL-cell_02 = 'Shift Asset Depreciation - Period/Year-wise Report.'.
    APPEND WA_EXCEL TO IT_EXCEL.
    PERFORM APPEND_BLANK_LINE USING 1.
    ENDFORM. " DISPLAY_TOP_OF_PAGE
    *& Form APPEND_BLANK_LINE
    text
    -->P_1 text
    FORM APPEND_BLANK_LINE USING P_LINE TYPE I.
    DO P_LINE TIMES.
    CLEAR: WA_EXCEL.
    APPEND WA_EXCEL TO IT_EXCEL.
    enddo.
    ENDFORM.
    *& Form EXPORT_TO_EXCEL
    text
    --> p1 text
    <-- p2 text
    FORM EXPORT_TO_EXCEL .
    DATA: L_FILE_NAME(60) TYPE C.
    Create a file name
    CONCATENATE 'C:\' 'Shift_Depn_' SY-DATUM6(2) '.' SY-DATUM4(2)
    '.' SY-DATUM+0(4) INTO L_FILE_NAME.
    Pass the internal table (it_excel which is already populated )
    to the function module for excel download.
    CALL FUNCTION 'WS_EXCEL'
    exporting
    filename = L_FILE_NAME
    tables
    data = IT_EXCEL
    exceptions
    unknown_error = 1
    others = 2.
    if sy-subrc <> 0.
    message e001(ymm) with 'Error in exporting to Excel.'.
    endif.
    ENDFORM. " EXPORT_TO_EXCEL
    *~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    When you click the button - Export to Excel ( GUI-Status) you'll be able to export the content of the Internal Table to an Excel file .......
    Regards,
    Abir
    Don't forget to award points *

  • How to generate excel file as output using OWB

    Hi,
    I have a requirement to generate an excel file as output using OWB.
    I am trying for a direct approach to create excel files.
    Though I know that excel can be created from a .csv file, I am looking for a direct approach to generate excel file without involving any .csv to excel conversion externally.
    Regards,
    Sri

    so, we are trying to do it by the help of oracle heterogeneous services. In my opinion it is possible (it depends on feature of ODCB Excel driver)
    For more details look at thread (it is about MS SQL Server but maybe it helps)
    Oracle to SQL SERVER
    Regards,
    Oleg

  • How to generate MT files from Oracle EBS Payables

    Hi, does anyone has experience in generating MT files from Oracle Payables?
    All contributions are welcome...

    Hi,
    are you talking about MT-940 format files? If so, what is the use case behind this issue?
    I created a custom loader process to upload MT-940 bank statements into Cash Management
    some time ago, but as far as i understood your question, you want to create those files based
    on payables data?
    Regards

  • How to import excel file in oracle 10g suit

    Respected all,
    i am working d2k6i now i am going to 10g suit and i want to import excel file so anybody help me how to do it? Thanks in advance.

    Hi,
    This forum is dedicated to Oracle SQL Developer Data Modeler, so it is possible to get an answer here, but it is not very likely.
    Try to get help in in more appropriate forum from here
    https://forums.oracle.com/forums/main.jspa?categoryID=84
    Regards

  • How to generate trace file in oracle application forms

    hi
    I want to generate trace fle in oracle application
    Regards
    9841672839

    Hi,
    Refer to the following documents.
    Note: 296559.1 - FAQ: Common Tracing Techniques within the Oracle Applications 11i/R12
    https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=296559.1
    Note: 130182.1 - HOW TO TRACE FROM FORM, REPORT, PROGRAM AND OTHERS IN ORACLE APPLICATIONS
    https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=130182.1
    Regards,
    Hussein

  • ** How to Generate Excel File as Output From Payload

    Hi Friends,
    I am doing Proxy to File scenario. But, the requirement is instead of  text file, we need to produce Microsoft Excel File from XML payload.
    How do we achieve this ? Any idea friends...
    Thanking you.
    Kind regards
    Jegathees P.

    Hi Jegatheeswaran ,
    You can use APIs available to convert xml files to excel file.
    You can write module to achive the same.
    Thanks
    Sunil Singh

  • How to Generate Excel file??

    I want to capture data from Database(MySQL) and Generate an Excel File,
    is it any method can do it??

    The simplest thing to do is to create a .csv file.
    You can create Excel from java. There are a number of APIs to this but I would start with
    http://jakarta.apache.org/poi/

  • How to Display PDF File on Oracle Report 10g

    Dears,
    i have a PDF File on the server,
    also i need to display this file into rdf report.(Embed the PDF file into Report)
    Regards

    Dear Inol,
    I have the same problem I want to embded a PDF, word Doc OR Image in report 10g.
    And I put the read from file property YES and File Format OLE2
    and it doesnt work by run_web_report by repport server. while in run report layout it works.
    And my report server on the same Pc "The file path on the same server". or you can say that im working on the server where the path of the file exists and it doesnt work also.
    So what do you think that i have to do to solve this problem.\
    by the way i try to Genarate the report to a file in spacefic path then open it. and it didnt work also.
    any help will be apreciated.
    thanks in advance.
    Ashraf

  • How to generate XML file from oracle database query result

    Hi dudes,
    as stated on the subject, can anyone suggests me how can i achieve the task stated above??
    Here is a brief description of my problem:
    I need to create a XML file once i query from the oracle database, and the query result returned from the database will be stored in XML file.
    I'd searched around the JAXB, DOM, SAXP and the like basic concepts, but i still don't know how to start??
    Any suggestions ???

    Read this:
    http://www.cafeconleche.org/books/xmljava/chapters/ch08s05.html
    You might have to read more of the book to understand that chapter.

  • Generate pdf file from 9i reports and save it in C:\oracle_reports\

    i want to generate a file from oracle reports in PDF format and want to save it on already defined path.
    c:\oracle_reports\
    right now pdf generation of report is working fine but before generation of pdf report system prompt me or open a dialogue box to save my pdf file on drive. i dont want to see these dialogue box or prompt me to explicitly save it.
    i want all the work done automatically.
    regards
    ------------ source code--------------
    PROCEDURE PRINT_PROC IS
    repid REPORT_OBJECT;
    v_rep VARCHAR2(100);
    rep_status VARCHAR2(20);
    pl_id ParamList;
    report_path varchar2(100);
    aud_sno varchar2(1000);
    aud_type varchar2(500);
    BEGIN
         pl_id := Get_Parameter_List('report_data');
         IF NOT Id_Null(pl_id) THEN
              Destroy_Parameter_List( pl_id );
         END IF;
         pl_id := Create_Parameter_List('report_data');
         User parameters : Customize these to fit your report
         report_path := :GLOBAL.Web_BASE_PATH||:GLOBAL.PATH_SCM||'REPORT\scm_rfq.rep';
    -- Initialize your report parameters here
         Add_Parameter(pl_id, 'p_cmp_code'                     , TEXT_PARAMETER, :global.company_code);
         Add_Parameter(pl_id, 'p_rfq_sno'                     , TEXT_PARAMETER, :document_sno);
         Add_Parameter(pl_id, 'P_PATH'                               , TEXT_PARAMETER, REPORT_PATH);
    Standard parameters: Don't change
         Add_Parameter(pl_id, 'PARAMFORM' , TEXT_PARAMETER, 'NO');
         Add_Parameter(pl_id, 'PAGESTREAM' , TEXT_PARAMETER, 'NO');
         Add_Parameter(pl_id, 'MAXIMIZE' , TEXT_PARAMETER, 'YES');
         -- end standard parameters
         repid := find_report_object('REPORT_OBJ');
         SET_REPORT_OBJECT_PROPERTY(repid,REPORT_EXECUTION_MODE,BATCH);
         SET_REPORT_OBJECT_PROPERTY(repid,REPORT_COMM_MODE,SYNCHRONOUS);
         SET_REPORT_OBJECT_PROPERTY(repid,REPORT_DESTYPE,CACHE);
         SET_REPORT_OBJECT_PROPERTY(repid,REPORT_SERVER,'rep_oas');
         SET_REPORT_OBJECT_PROPERTY(repid,REPORT_FILENAME,report_path);
    -- SET_REPORT_OBJECT_PROPERTY(repid,REPORT_DESFORMAT,'htmlcss');
    SET_REPORT_OBJECT_PROPERTY(repid,REPORT_DESFORMAT,'pdf');
    SET_REPORT_OBJECT_PROPERTY(repid,REPORT_DESNAME,'\\ORCLSRV\UTL_MAIL\'||:doc_type||:receiver_sno||'.pdf');
         v_rep := RUN_REPORT_OBJECT(repid,pl_id);
         rep_status := REPORT_OBJECT_STATUS(v_rep);
         WHILE rep_status in ('RUNNING','OPENING_REPORT','ENQUEUED')
         LOOP
         rep_status := report_object_status(v_rep);
         END LOOP;
    END;

    If you use rwclient you could that easily, from a Form, it requires additional steps.
    Look at this thread Re: save report

  • How to export the data from an excel file to Oracle database by using macro

    Hi,
    I want to export data from an excel file into Oracle database.There is one method that by creating the macros through excel we are able to do this.
    can anybody please send me the code to create macros?
    Thanks in advance.
    Regards,
    Surendra.V

    There are several resources on the web, but you could start analyzing if this code fits your needs --> VBA Macro for Excel 2003 Export of Text File with Comma and Quote Delimiters.
    ~ Madrid

  • Help Required:How Upload Excel file Into Oracle Table Using PLSQL Procedure

    Please Help , Urgent Help Needed.
    Requirement is to Upload Excel file Into Oracle Table Using PLSQL Procedure/Package.
    Case's are :
    1. Excel File is On Users/ Client PC.
    2. Application is on Remote Server(Oracle Forms D2k).
    3. User Is Using Application Using Terminal Server LogIn.
    4. So If User Will Use to GET_FILE_NAME() function of D2K to Get Excel File , D2k Will Try to pick File from That Remote Server(Bcs User Logind from Terminal Server Option).
    5. Cannot Use Util_File Package Or Oracle Directory to Place That File on Server.
    6. we are Using Oracle 8.7
    So Need Some PL/SQL Package or Fuction/ Procedure to Upload Excel file on User's Pc to Oracle Table.
    Please Guide me wd some Code. or with Some Pl/SQL Package, or With SOme Hint. Or any Link ....
    Jus help to Sort This Issue ........
    you can also write me on :
    [email protected], [email protected]

    TEXT_IO is a PL/SQL package available only in Forms (you'll want to post in the Forms forum for more information). It is not available in a stored procedure in the database (where the equivalent package is UTL_FILE).
    If the Terminal Server machine and the database machine do not have access to the file system on the client machine, no application running on either machine will have access to the file. Barring exceptional setups (like the FTP server on the client machine), your applications are not going to have more access to the client machine than the operating system does.
    If you map the client drives from the Terminal Server box, there is the potential for your Forms application to access those files. If you want the files to be accessible to a stored procedure in the database, you'll need to move the files somewhere the database can access them.
    Justin

Maybe you are looking for

  • Fix For Slow Printing To IPP Printer Pool

    Here's a fix that might help someone out there: I have a printer pool with two HP Laserjet printers that's shared via IPP on an Xserve running Mac OS X Server 10.5. One of the printers is offline with a fuser error, so as expected, the server is send

  • Regarding work flow in the organisation

    Hello,       I am new to SAP XI. I want to join as a SAP XI developer. So I want to know about the work flow in the organisation. Means who will raise issues and who will take care of it first. and how it will reach to SAP XI developer.     What are

  • Sound card advice to a MacBook Pro

    I am looking to purchase a soundcard for my MacBook Pro. I am going to be using my laptop for a moderate amount of DJing while also using the M-Audio products to go along with it. Will eventually get to hooking up two ipods and mixing with the two th

  • Doubt in joins

    hi, i have four tables tab1,tab2,tab3,tab4 tab1(columns are name,timestamp,id) name, timestamp ,id name1 5/28/2007 12:45:18 PM 01 name2 5/28/2007 12:44:18 PM 02 name3 5/28/2007 12:43:18 PM 03 name4 5/28/2007 12:43:18 PM 04 name 5 5/28/2007 12:42:18 P

  • Change date help icon inside table

    Hello, I've created a new theme and I've changed the date help icon(Theme Editor/Simple Elements/Labels and Fields). I can see new icon in portal but when displaying it from a cell inside a table, it displays the standard icon. Please, I need to show