3.0 Shared Component - Report Format - all PDF

Greetings,
Details
I have been working with the REPORTS - REPORT QUERIES section of APEX 3.0
The testing I have been doing is very simple, but I am running into a bit of a stumper.
I have created 4 report queries on the EMP table (SELECT * FROM EMP) that all use the same REPORT LAYOUT. The RTF file which is the template is a very simple - show all columns and rows for the EMP table (14 rows).
I have set each of the 4 report layouts to a different format.
1 - PDF
1 - EXCEL
1 - WORD
1 - HTML
I am NOT using the ITEM to dynamically set the format.
I can TEST each of the reports in the shared component area, and they test OK with a success rate of 75%.
The EXCEL format does not export correctly. (using Excel 2002 on the client) It is a bit of a mess. (Works in the XML publisher template builder on the client.. so the format is not the issue.)
More curious is the behavior when I put this application. I have created a LIST of the 4 report formats. All 4 return the PDF format when used.
To see the Application:
http://apex.oracle.com/pls/otn/f?p=34096
Question Summary:
1 - Has anyone run with and tested the RTF style report layouts out to Excel?
2 - The approach described usees 4 report queries against 1 layout. Is this a VALID use of the report functionality?
3 - Why would all the reports try to use PDF when they test in the correct formats?
Best Regards and Thank You.
-- Tim

Tim,
The Excel output is not strictly XLS, it's actually HTML formatted in a way that Excel understands and through setting the MIME-types we make it open in Excel. I have to try reproducing your specific problem with Excel 2002. If you could send me your RTF layout and the end-result ([email protected]), I can take a look.
Your approach using 4 different queries with the same layout is perfectly fine. Ideally of course, you would not have to replicate them same query four times, so we are considering a shared query concept for future version of Application Express.
You specific problem with the output format being PDF at runtime appears to be a bug, I'll investigate further. Meanwhile one work-around would be to use a report region instead. If you're using the same SQL query as the source, you can associate the same report layout (on the report print attributes page). You could also create a "container" page for that report region, that's never actually called by the end user, and then have a button pointing to the URL below for printing. It would then work just like your report queries, only that you now would get the requested format:
f?p=&APP_ID.:[REPORT PAGE ID]:&SESSION.:FLOW_XMLP_OUTPUT_R[REPORT REGION ID]
so if your app ID is 34096 and your "container" page e.g. 99, and on page 99 your report region ID would be 1234567890, then use this URL as the button target:
f?p=&APP_ID.:99:&SESSION.:FLOW_XMLP_OUTPUT_R1234567890
Hope this helps,
Marc

Similar Messages

  • Bind Variables and Shared Component Report Query

    I have a query in a region report which I have replicated to a shared component report query.
    Both queries reference page items as bind variables in the where clause.
    The report region on screen shows the correct results but the report query shows "no data". This is the case when running "Test Query" and "Download XML data" from the shared component report query definition. If I hardcode the variable names I get rows returned, If I use bind variables - and specify the values for these variables I get no data. THe XML file contains the tags for each bind variable I have specified but has no data between the tags. I have Ticked the box to include application and session state but it appears that the bind variables are not being used.
    When I use my report query in the application (URL tied to a button) I get the same problem, the binds are not being passed to the report query.
    Can someone please clarify if this is a bug or not? And if not, how can I get it to work.
    I am using Apex 4.0.2
    Thanks
    Kathryn

    Hi
    To confirm, yes I selected the bind variables. I used these in the report layout, but the xml file has them as empty i.e.
    <P0_START_DATE><P0_START_DATE/> with nothing in between.
    IN the Test Query section, if I put real values in the boxes for the bind variables, I get no data found. If I hardcode the values into the query, I get the data.
    I've repeated the create report query many times and have created a report layout in RTF. I can use the layout with my region - in the print attributes and the layout works with the query but I need to create a PDF using 2 queries - ROWSET1 and ROWSET2. I can generate the XML but the values in the rows are all empty. When I use the layout with a report query instead of the region, I get no data even though I have used the same sql and have selected the bind variables. I was using variables from page items on page zero but have also tried using page items on the current page, the result is the same.
    I need to use a report query and a report layout as I need data from 2 queries in the PDF.
    I looked at your demo - what happens if you add a second sql query to the report query - is there any chance I can look at the back end (developer access?)
    Thanks for your input
    Kathryn

  • Setting a bind variable in a Shared Component Report Query

    I have defined a Shared Component Report Query in APEX using a bind variable similar to below
    Select name, id , ....
    from asset
    where id = :id
    I have also created a Report Region that displays a table where one of the columns contains a value I would like to be a link column that can launch the Report Query and pass its value to the bind parameter :id in the report query. This in turn would generate a pdf report for the details associated with that column. I am having problems setting the :id bind parameter. How do I do this?
    Can anyone help?
    Thanks

    The bind values are set from session state. So if try something like this:
    Select name, id , ....
    from asset
    where id = :P1_ID
    With P1_ID being a page item, for which you set the session state / value before generating the PDF file. So assuming you already have a page with a report and a page item, and that page item is already used in your report, then you could just create a button to download the PDF, make sure the button is a submit button, and create a branch pointing to the report query URL (or in 3.1 use the create button wizard, to do this declaratively.)
    Regards,
    Marc

  • Using bind variables in Shared Component Reports not working

    I've created a report query as a shared component in my APEX application. I'm calling the report on a page via a button. The query behind the report has bind variables for period and entity fields which are both defined on Page 0. I can run the query and return values just fine, but when you run the report from the page via the button, I get no values back. Does anyone know a trick to getting this to work? I've been working in APEX for about a month and I don't have much developer experience so any help is appreciated.
    Regards,
    -Steve

    Rohit,
    Thanks for your response. We are using APEX version 4.2.1.00.08. I do have Session State enabled and have put the required page items in the list. Here is my report query (highlighted lines contain the bind variables):
    SELECT TAX_DIVISION.DIVISION_CODE Division,
    TAX_ENTITY.ENTITY_CODE Entity_Code,
    DECODE(TAX_ADJUSTMENT.CATEGORY_DESC,'Net Income/(Loss)',1,'Permanent Adjustment',2,'Temporary Adjustment',3,4) Category_Desc,
    TAX_ADJUSTMENT.CLASSIFICATION Classification,
    TAX_ADJUSTMENT.ADJUSTMENT_CODE Adjustment_Code,
    SUM(NVL(NVL(TAX_ENTITY_ADJUSTMENT.OVERRIDE_AMT,TAX_ENTITY_ADJUSTMENT.ADJUSTMENT_AMT),0)) Tax_Amount
    FROM TAX_DIVISION,
    TAX_ENTITY,
    TAX_ENTITY_ADJUSTMENT,
    TAX_ADJUSTMENT,
    TAX_PERIOD
    WHERE TAX_DIVISION.DIVISION_ID = TAX_ENTITY.DIVISION_ID
    AND TAX_ENTITY.ENTITY_ID = TAX_ENTITY_ADJUSTMENT.ENTITY_ID
    AND TAX_ENTITY_ADJUSTMENT.ADJUSTMENT_ID = TAX_ADJUSTMENT.ADJUSTMENT_ID
    AND  TAX_ENTITY_ADJUSTMENT.PERIOD_ID = :P0_PERIOD_ID
    AND  TAX_ENTITY_ADJUSTMENT.YEAR_ID = :P0_YEAR_ID
    AND  TAX_ENTITY.DIVISION_ID = :P0_DIVISION_ID
    AND TAX_ADJUSTMENT.ADJUSTMENT_CODE = 'IBIT'
    GROUP BY TAX_DIVISION.DIVISION_CODE ,
    TAX_ENTITY.ENTITY_CODE ,
    DECODE(TAX_ADJUSTMENT.CATEGORY_DESC,'Net Income/(Loss)',1,'Permanent Adjustment',2,'Temporary Adjustment',3,4),
    TAX_ADJUSTMENT.CLASSIFICATION ,
    TAX_ADJUSTMENT.ADJUSTMENT_CODE
    HAVING SUM(NVL(NVL(TAX_ENTITY_ADJUSTMENT.OVERRIDE_AMT,TAX_ENTITY_ADJUSTMENT.ADJUSTMENT_AMT),0)) !=0
    ORDER BY DIVISION_CODE, DECODE(TAX_ADJUSTMENT.CATEGORY_DESC,'Net Income/(Loss)',1,'Permanent Adjustment',2,'Temporary Adjustment',3,4), CLASSIFICATION, ENTITY_CODE, ADJUSTMENT_CODE
    The query returns data when I set the bind variables and test in the report queries screen. When I assign the report query URL to the button in the application and run from there, I get no results.

  • 9ias reports format problem PDF - HTML - HTMLCSS

    I have a report to be printed in PDF Or HTML or HTMLCSS format. I am using Oralce 9ias and Reports 9i. PDF output is OK. But the same output in HTML and HTMLCSS are not coming properly.
    For e.g. I have a field with size as 150. I am setting Vertical elasticity of the field as expand. But in HTMLCSS if the field size is 150 it merging and not displaying properly. In HTMl it is coming properly. But the date fields i display gets wrapped into two lines.
    Is it a bug or any solution present for this

    Hi Srinivasan
    Reports PDF output is high fidelity offering from Oracle Reports. I recommend you to use it as much as possible.
    Regarding HTML/CSS, I feeling is that is not currently possible to format the way you say you want to. If this issue is very critical to your business, I suggest you to contact Oracle Support.
    Regards
    Sripathy

  • APEX Report Formatting in PDF Help

    Hello there,
    I was asked to create a report in APEX that will generate a report in PDF. The report will have the first column that will print Institution names, the subtotal should print the institution sector (eg: research university or state University etc..) in the institution name, it also should be in italic and bold and indented about 5 point and the total should print "Total" in the Institution column indented, bold and italic. All the subtotals and total values must be bold and italic. At least bold if not italic.and the second column will be values for headcount. To demo this, I used Oracle OEHR data where I can print Employee name and will print for subtotal the employee job ittle and the total emploees.
    I want to have the result without rows and columns borders as well as no background color. I want to print the subtotal and total in bold and italic. Can you advise how to solve this problem? To see the actual report please visit https://app.usg.edu/portal/page/portal/USG123_10G/USG_ACA_TAB
    and click on the report to generate the report. Please also advice if this site functionality can be reproduced in APEX and how much will be your efforts?
    select NVL(OEHR_EMPLOYEES.FIRST_NAME, NVL( OEHR_JOBS.job_title, 'Employee Total')) as Employees,
    sum(OEHR_EMPLOYEES.SALARY) as SALARY,
    from OEHR_EMPLOYEES OEHR_EMPLOYEES,  OEHR_JOBS OEHR_JOBS
    where OEHR_EMPLOYEES.job_id = OEHR_JOBS.job_id
    group by rollup(OEHR_JOBS.job_title, OEHR_EMPLOYEES.FIRST_NAME)
    order by OEHR_JOBS.job_title

    You version of WORD defaults to using printer metrics. There are 2 ways to resolve the issue. 1. go to print and select the Adobe PDF printer, back out and fist the document issues in WORD. 2. Deep in the options of WORD, there is a selection for using printer metrics (I assume your version also has this selection). Uncheck that and the problem should go away. You could also change your default printer to the Adobe PDF printer.
    WORD 2007 was changed to have the default set to NOT use printer metrics. All previous versions used the metrics. Thus when you change the printer, WORD reflows the document. The result may be errors in bookmarks, page numbers, and related issues.

  • Shared component Report Queries

    Hi All,
    Can anybody tell how to add report queries(shared components) in button or how to access report queries.
    Thanks

    Hello,
    If you can go for BI Publisher that would be very nice and integrates awesome.
    To install and configure you can follow this: http://dgielis.blogspot.com/2007/06/testing-oracle-bi-publisher-with-apex.html
    There's also a guide of Oracle here: http://www.oracle.com/technology/products/database/application_express/html/configure_printing.html
    If you can't go for BI Publisher, you can use Apache FOP for ex or PLPDF (but that's something totally different from the other two)
    Regards,
    Dimitri
    http://dgielis.blogspot.com/
    http://www.apex-evangelists.com/
    http://www.apexblogs.info/

  • Interactive Report - download to PDF, fixed column widths-- why

    We are using 4.1.1.00.23, we have just installed the Apache/FOP solution to download our Interactive Reports to PDF.
    The issue is that it seems that no matter what we do the column widths become evenly distributed in the downloaded report. When the report only has 5-8 columns this is ok, doesn't look as good as we would like but it is ok. The problem comes when we have many columns, then all of the columns get shrunk down to these little columns that become totally useless.
    Also, it appears that no matter what page size I define in the Page Attributes it sizes the columns to fit on an standard page (8.5x11).
    The question I guess is: Is there a way to download an Interactive Report to PDF, that looks exactly like the report that is displayed for the Interactive Report?
    We have been looking at lots of the documentation and fear we are missing something because it appears that most solutions talk about creating a "Shared Component" Report Query and Report Layout, which when you have a hundred interactive reports seems crazy....why can't we just download what we see on the screen.
    If there was a way to put Headers/Footers on HTML download, then we would not need to do this, but I have not found a way to do that either.

    From our understanding, it looks like we would have to create another report for each of our existing Interactive Reports, which would be a JasperReport or something.
    We know there is something with the XSL-FO templates, is that what iReports can do for us? Really this is a new world for me, so I do fear that I might be asking my question wrong.
    Like I said maybe we are missing something. We were able to get the FOP to work, but the problem with that is all of the columns are evenly distributed widths. On some reports, which have many columns, there could be a name column that needs to display 50 characters, but then the next field only has 5 characters. It appears that without creating an additional report or report layout for each report we cannot print the results of the interactive report.
    Maybe I am completely missing something in all of this, but I find it hard to believe that we have to create multiple versions of a report just to be able to print it. If we had just wanted to create a static report, then I would have continued using Oracle Reports, like we have for the last 20yrs.

  • Open a PDF report from a PDF report

    I would like to open a PDF report from a PDF report, but in a new IE window.
    I have the following code attached to an item in the report:-
    function F_RECONFormatTrigger return boolean is
    begin
    IF trim(:btch_ref) = 'PL' and trim(:recon) is not null and trim(:recon) <> ' ' then
    srw.set_font_weight(srw.bold_weight);
    srw.set_font_style(srw.underline_style);
    srw.set_text_color('blue');
    srw.set_hyperlink_attrs('onMouseover "window.status="Click here to see what is in your shopping basket"; return true"'||'onMouseout ="window.status=" "; return true"');
    srw.set_hyperlink('/reports/rwservlet?cmdkey=famis+desformat=pdf+report=FAMREP011+p_orderno='||trim(:recon));
    srw.set_hyperlink_attrs('target=_blank');
    -- srw.set_hyperlink_attrs('target="_blank"');
    END IF;
    return (TRUE);
    end;
    All of the commands work except for the 2 srw.set_hyperlink_attrs commands. The "onMouseover" and the "target" seem to have no effect. Can anyone help?
    Thanks in advance
    Michael

    The built in srw.set_hyperlink_attrs does not work , if the report format is PDF. There is no way to open another PDF report from a PDF report in a seperate window. Also think there is no way to hide URL which apperars when the mouse pointer moves over the hyperlink.
    In other report formats like HTML, the built in srw.set_hyperlink_attrs works.
    Kranthi

  • Generated pdf file from shared component missing checkbox

    I have created a report queries under shared component. The output format is pdf. I have created a rtf template. In the template, I have to insert a checkbox. At first it didn't work, then I have added Checkbox shows fine when I preview the report using Microsoft Word (Add-Ins). I have added following two lines in the xdo.cfg file (under C:\Program Files\Oracle\BI Publisher\BI Publisher Desktop\Template Builder for Word\config):
    <truetype path="C:\WINDOWS\fonts\wingding.ttf" /> and
    <property name="rtf-checkbox-glyph">Wingdings;0254;0168</property>
    After that, when I view output from word, it shows checkbox correctly. However, when I click Test Report button from Apex, everything looks fine except missing checkbox. It shows ? symbol instead of checkbox symbol. So something must been done in apex server side. Does anyone know how to config in the apex server side to make checkbox show up in the pdf file? Thanks advance.

    You need to setup BI Publisher. Follow the instuctions at http://chandramatta.blogspot.com/2009/10/bi-publisher-how-to-print-check-box-on.html

  • Font problem in reports produced in PDF format

    Dear all,
    All our reports are developed by developer suite 10g (under windows) and deployed on an Application Server 10g (on Linux).
    We had a problem with displaying the arabic letters, but this was solved by following the steps in the metalink Note no 726205.1 for generating arabic pdf reports on unix.
    Now, the problem is that the font used in the reports is ARIAL, but when the reports are displayed (in PDF format) the font is TAHOMA. This font conversion happens in both Arabic and English reports !
    I wonder how can I correct this behaviour.
    Thanks in advance for your time.
    Naglaa

    Steve,
    I remember that fonts in PDF generated by Oracle Reports is a big topic and a subject of many Metalink notes (metalink.oracle.com).
    Note.210318.1 Ext/Pub How To use font embedding in Reports 9i for PDF output
    Note.207711.1 Ext/Pub How to Use Font Subsetting in Reports 9i for PDF Output
    Note 232975.1 "Windows/Unix Font Issues: What Information is Required to address the Issue and How to Work Around Issue"
    Especially on Unix and Linux systems, there are some font mapping required. I suggest to run this question on the Reports forum here on OTN where I think you have better chances for an answer.
    Frank

  • Generate a Shared Component LIST in XML or JSON format

    Greetings...
    I am using the LIST functionality within the Shared Component area of our application in order to maintain a menu/navigation list. I'm utilizing all of the features of the LIST Shared Component -- links, authorizations, conditions, comments, etc. This list will appear on every page, so I'm putting it on page zero.
    I'd like to get this list in an XML, JSON, or some format so I can manipulate it in javascript to display it. I guess another way to put it is that the template options for a LIST template seem to be very detailed and specific (which is great in general) and I am looking to just get the data out and display it myself.
    I can easily enough write a SQL query to produce the hierarchy proper hierarchy of the list, but I would be circumventing the method ApEx uses to implement all of the conditions and authorizations on the entries. I see there are APIs for both generating the list and also checking conditions, but neither of them are accessible to my custom schema and I wasn't sure if I should even attempt to reproduce them.
    Basically, I'd like to use the built-in functionality of the LIST Shared Component, but use my own display methods.
    Shane.

    http://htmldb.oracle.com/pls/otn/f?p=20297:14

  • Why Reports format behaves different in Excel and browser(if desformat=html or pdf)?

    1-Why Reports format behaves different in Excel and browser(if desformat=html or pdf)?
    2-I made three queries Q1,Q2 & Q3 and linked them with proper field links but suppose Q3 returns no records for some Q1&Q2 records & when the report runs for delimited options it reflects only those records as output for which all the queries return records(if Q3 returns no record then the related records from queries Q1,Q2 don't reflect) while the output in desformat=html or pdf is ok..
    can you please resolve my problems
    ( I have installed patch 5a in my report server machine)
    Thanks & Regds.
    Suneel
    null

    What do you mean by "different"? (In our
    experience, Oracle html output has too many
    columns, which are not visible in the
    browser but are obvious in Excel.)
    We build our own html programmatically, so
    that Excel matches the browser more closely.
    -- Allan Plumb

  • Difference between pdf and html report format

    Why HTML report printouts truncate from the right-end side, compare to the pdf report format ?, do i need to change anything
    while running report through HTML format

    The printing from html output is majorly affected by browser settings. Once you try to change the left and right margins in page setup before printing, I solved this problem in this way , it may work for you. Let me know if it works or if you overcome it by other ways.
    with regards
    wara

  • Production order wise report  of  all component.

    dear all
    I want production order wise report  of  all component.
    1) quantity required 2)issue quantity3)currect stock
    I got  quantity required and issue quantity field in co24 but i didnt get currect stock field(unrestricted stock) in that t-code
    Is any t-code is available ?
    rgds
    Surendra

    Hy Surendra,
    In any of the standard SAP reports you will not find the Goods Movements of Particular order along with available Component stock.
    Goods movements report of the Production / Process order is static report once the order is close.While Stock report is variable report and may be change Time to Time.
    I think if you wish such kind of report then you have to go for Z reorts.
    You can find all the Goods Movements of Order in COOISPI/COOIS/IW3M but there is not available stock report.
    Regards,
    Dhaval

Maybe you are looking for