Interactive report URL syntax

Hi
I'm using Apex 3.1.2, and am fairly new to using Interactive reports. I've found the URL syntax to apply a filter on an IR, and was just wondering if it is possible to apply a sort, or even open a saved report from a URL link? I am well aware that I can work around it (using different pages with a sort pre-applied etc) but was hoping that I could do everything on one page.
Thanks!
-Marc

Hi Marc,
I just read over the document and it doesn't appear that we can do it via the URL, however you may be able to do this using JS.
Try this (I did this as a test on the emp table)
//Send filter request
var get = new htmldb_Get(null,$v('pFlowId'),'APXWGT',$v('pFlowStepId'));
get.addParam('f01','EMPNO');
get.addParam('f01','=');
get.addParam('f01','7369');
get.addParam('f01','');
get.addParam('f01','minutes');
get.addParam('p_widget_action','FILTER');
get.addParam('p_widget_action_mod','ADD');
get.addParam('p_widget_mod','ACTION');
get.addParam('p_widget_name','worksheet');
get.addParam('x01',$v('apexir_WORKSHEET_ID'));
get.addParam('x02',$v('apexir_REPORT_ID'));
get.addParam('x03','EMPNO');
var gReturn = get.get();
//Refresh report request
var get = new htmldb_Get(null,$v('pFlowId'),'APXWGT',$v('pFlowStepId'));
get.addParam('p_widget_mod','PULL');
get.addParam('p_widget_name','worksheet');
get.addParam('x01',$v('apexir_WORKSHEET_ID'));
get.addParam('x02',$v('apexir_REPORT_ID'));
get.addParam('x03','EMPNO');
var gReturn = get.get();
//Refresh HTML report
$s('apexir_WORKSHEET',gReturn);
I'll try to put a post on my blog about the full solution to this shortly ([http://apex-smb.blogspot.com/])
Martin

Similar Messages

  • Row filter on Interactive Report via URL parameter

    Hi,
    I've searched the forum but can't find a concise answer.
    Is it possible to pass a parameter (p_X) from one page to another via the url and then use p_X to act as a row filter in an Interactive report?
    Thanks for the help
    Joel

    Joel -
    Read the link that Andy posted. It is a pretty good source. This topic is not really that difficult to do. I have done it several times. Make sure that you understand the URL syntax for APEX. If you need a refresher on this take a look at http://www.oracleapplicationexpress.com/tutorials/55
    Austin

  • How to display images by using URLs in Interactive Reporting

    Hello everybody,
    My client has the Hyperion System 9.3 suite.
    We have a report in Interactive Reporting showing product data.
    The source for the report is a relational database (SQL Server).
    The data is grouped by product.
    My client needs the product's picture (jpg) in the report.
    The problem is that product images are not available in the relational database but via URL like this:
    http://client_domanin//Hyperion/id_product.jpg
    (the name of the image equals the id of the product).
    I was thinking to solve this problem using Java Script.
    I don't know Java Script and don't know how to 'integrate' the JavaScript code with Interactive Reporting.
    How should the Java Script look like?
    Any help will be extremely appreciated.
    Thank you all!
    Daniela

    You might be able to do it if you are using the iHTML view of the Report not the Interactive Reporting Web Client (Plug-in)
    I do not have a 9.x server available to test this so it is guess on how i did it once in a Proof of Concept.
    In Results section Create a Computed Item that will be the HTML tag for the Graphic
    the syntax would look something like below
    '<IMG SRC = "http://client_domanin//Hyperion/" + id_product + ".jpg">'
    WHERE id_product is a column in your Data.
    Again this will not show a graphic when viewed with Interactive Reporting Web Client or Desktop Client.
    Good Luck, hope this is helpful
    Wayne

  • Passing values w/special characters in URL into an interactive report

    Hello,
    I have a problem and Ive been all over these forums and reading/trying everything I can to get something to work. I have a page that has a field called Name Search. The field is a TextField with autocomplete type. If I select a company name that contains special characters, like 'Blue Shield of California Life *&* Health Insurance Company', when I click go button (using a branch), it is supposed to pass this value into the URL to populate IR_COMPANY_NAME on the interactive report page to create the report filter. However, when it goes to the IR page, it actually filters on 'Blue Shield of California Life *& amp;* Health Insurance Company' with 'amp;' instead of & and doesnt find any matches. In the page source it is actually 'value="Blue Shield of California Life *& amp; amp ;* Health Insurance Company." Here is the URL that it produces:
    http://webtest2:7775/apex/f?p=102:IRCompanyList:995769774353901::NO:5,RIR:IR_COMPANY_NAME,P5_COMPANY_NAME:Blue%20Shield%20of%20California%20Life%20%26amp%3B%20Health%20Insurance%20Company,Blue%20Shield%20of%20California%20Life%20%26amp%3B%20Health%20Insurance%20Company
    The interesting thing is that I have another page that has a clasic report that lists all compnaies by name and the company_name is a link that passes the company name into the exact same IR and it works fine. In the page source it is value="Blue Shield of California Life *&amp;* Health Insurance Company" Here is the URL that this page produces:
    http://webtest2:7775/apex/f?p=102:5:995769774353901::NO:4,RIR:IR_COMPANY_NAME,P5_COMPANY_NAME:Blue%20Shield%20of%20California%20Life%20%26%20Health%20Insurance%20Company,Blue%20Shield%20of%20California%20Life%20%26%20Health%20Insurance%20Company
    I have modified every field involved changing between encoding, no encoding, changing display types (Standard Report Column, Remove HTML and escape special characters, etc). I have also attempted to encode the value myself prior to sending it to the next page. I have tried variations of the htf.escape_sc etc. I have also tried adding \&P2_COMPANY_NAME.\. I have also tried adding pl/sql to create a collection to store the values and then pl/sql to fill the values on the report page. It gives me the success message I setup, but it never actually fills the value.
    I am also having problems with another field that has a comma in it. I will wait to address that one to see if I can fix this first with hopes that it can be resolved by whatever I do to fix this issue.
    Any suggestions? I appreciate any feedback!
    Jen
    Edited by: J-Lig on Jul 13, 2012 10:20 AM
    Edited by: J-Lig on Jul 13, 2012 10:21 AM

    Thank you for your feedback!
    Yes, I forgot to mention that. It does come from a table, but company_name is not unique in that table. Meaning, it wouldnt know which ID to pass. Perhaps I should seperate the name out into another table and then I could pass the id. I was just hoping to get this to work programatically since the links from classic reports actually work correctly. I am starting to think this is a bug. This issue appears to have been addressed to make the links from reports pass the & correctly, but not in the branching?
    I have attempted to replace and then re-replace but I couldnt get it to work with IR_ fields as the filter fields are generated by the Interactive Report region. Do you have any insight working with those? Are there any tricks to it that I might be missing?

  • Interactive report row-level ("OR") filter via URL?

    I know you can perform a column level filter on an Interactive Report via URL, but can you do a row level filter?
    I want to do something like where column 1 = 'test' OR column 2 = 'test', not column 1= 'test AND column 2 = 'test'.
    Thank you and apologies if I am missing something in the documentation or other forum messages.

    Jeff,
    Thanks again for the response and for looking into it. However, if I am not mistaken, the url in that excerpt does the same thing as the URL I posted except that you used IREQ_COLNAME instead of IR_COLNAME (which defaults to EQ I believe).
    I want to see if a value is in column a OR column b, etc. The "OR" is the all important caveat.
    I would settle for being able to pass a value to the IR's main search box (that searches all columns of all rows) if I cannot do a targeted row level filter on a few select columns.
    If anyone knows how to do either of those things, that would be great information to have.
    Thanks,

  • Add a logo to the header definition of an Interactive Report

    Hi Folks.
    Using Apex 3.1 and BI Publisher.
    I am enabling an Interactive Report region to output to PDF & Excel.
    Has anyone managed to add a logo to the Header/footer definition in the Print Attributes section?
    Is it possible? The region definition does not understand simple HTML syntax.
    If anyone would let me know if a) They've done it or b) It ain't possible that would be great.
    Many thanks.
    Dogfighter.

    Just reading through this thread. So perhaps a few comments might be helpful:
    - Interactive report regions do currently not support Report Layouts, you're limited to the built-in generic layout and won't be able to include images
    - You can add a button to your interactive report region page which could initiate the download of a report query, when doing this, you would get the result set of your report query not the interactive report region, so even if the queries are the same, you might have different filters applied to your interactive report
    - You can in fact include static images in your RTF report layouts using the BI Publisher Desktop Word Plug-In and MS Word, so you can have logos etc in your PDF documents. But report layouts currently only work with report queries and classic report regions
    - You can also include dynamic images in your PDF, e.g. based on images stored in a BLOB column, there's currently a character escaping issue causing some trouble with this, which will be fixed in 3.1.1, more on that once 3.1.1 is out (soon)
    - the print server overwrite is designed to point to a different print server than the one configured for your APEX instance, not to point to a specific report. So if your instance has BI Publisher configured, but for a specific report you want to do some special rendering using your own code, you can write e.g. a JSP, Servlet, etc that's doing the rendering, and then point yout report to that URL
    Hope this helps, we do plan to add support for report layout to interactive report regions in the next full release of Application Express
    Regards,
    Marc

  • How to call function in INteractive Report!!

    Hi All,
    After investing on interactive report i have came to know that we can have only sql query but not Dynamic Sql query!
    By using PIPELINED FUNCTIONS we can use dynamic sql in Apex Interactive Reports.
    Here is the url for refernece- http://sungur.wordpress.com/2009/10/11/apex-interactive-reports-with-dynamic-sql/
    When i had tried to implement the the above one it is throwing error as
    Query cannot be parsed, please check the syntax of your query. (ORA-06575: Package or function GET_TABLE_ROWS2 is in an invalid state)
    Can any one help me out how to overcome the scenerio and resolve the problem?
    Since it is urgent can any one help me out to resolve it.
    Thanks in Advance,
    Anoo..

    Hi Anoo,
    Step 4:
    Create a process that will populate the heading page items with the relevant column name values from the dynamic query. This can be done by splitting the select line using the commas and extracting the dynamic column headers.This is Nothing But in Interactive report the column name is taking as a heading for every column, Otherwise we can go to change the column heading in report attributes(STEP 3).
    What they said we can try to change the column head dynamically.
    Like Ex:
    Select ename "Employee Name" from emp;The above Example we are taking ename but it displayed as Employee Name.
    I tried that but its taking 50 columns cant write that much of query.
    Now you got it?
    Cheers,
    Shan..

  • Interactive report's data not displaying on the edit form.

    I have an interactive report that contains 3 rows. When I click on the edit button next to one of these rows, the edit form displays the data from that row.
    But when I click the edit buttons next to the other 2 report rows, I get an error message that states: "ORA-01403: no data found. Error Unable to fetch row."
    I do not see why this is happening. The PK of the table involved is "Request Date", so the report's "Link Column" region sends the value "Request Date" to the item P54_Request_Date in the form page.
    Any idea why this would work correctly for one of the report rows but not for the other 2?
    Clearly, each of the report rows must have a value for the PK, so why would the form not be able to find the same row that the report displays? Is it a problem with the form's "Fetch Row from" process?
    Thanks.

    Hello:
    Your problems are primarily related to in your choice of a 'Date' type as the PK for your table. The Automated Row Fetch (ARF) process uses a SQL statement similar to the one below to retrieve a record from a table select c1, c2, c3 ... from tab where PK_col = :page_item_containing_PK_value . This would work find if the the 'page_item_containing_PK_value' were of the DATE data type. However, all APEX binds are done using varchar2. This means that the 'page_containging_PK_value' needs to have the char representation of the date that matches the default date setting on your database. So the page-item needs to be something like 'DD-MON-YYYY HH24:MI'. In your case the PK item is probably being set to 'DD-MON-YYYY' and therefore the fetch fails.
    Now, for the 'issue with the :' in the character representation of the date.The link on the report page uses the standard APEX URL syntax to construct the link
    f?p=App:Page:Session:Request:Debug:ClearCache:itemNames:itemValues:PrinterFriendly
    As you can see, the ':' acts as the separator that delineates the components that make up the APEX URL. So, having a ':' in the 'itemValues' component will make the APEX engine treat whatever follows the ':' in the value passed as a delimiter as opposed to being part of the value being passed.
    Varad

  • Building a search page that would lead to an interactive report

    I am a beginner in APEX ...
    Recently i was able to build an interactive report through an sql query and it worked out really well..
    Since my table has thousands of rows, users first want the ability to filter using a normal search boxes with few fields on it and then redirect that results into an interactive report...
    So my first page would contain several text boxes where users can input their search criteria and a submit button...
    On submitting the button, i should call the interactive report on the next page where users can further refine/filter or use all the features of interactive report..
    My question is how can i pass this search string from the first page to the interactive report page?? how do i handle the case where the users dont enter any values on some of the text boxes..
    Thanks

    user12253705 wrote:
    Yes Sven,
    Thats what i want to do...
    I probably will have atleast 6-8 text fields that the users might want to search ...
    how do i use those text fields as a filter to the interactive report???... currently digging up an example.
    meanwhile: have a look at this page to see how the apex-urls/links are composed:
    http://rokitta.blogspot.com/2009/07/apex-fp-syntax-with-flexible-parameter.html
    The item names / item values can be used to add some filter criteria also to an IR.
    Ok here is the example:
    You can set a filter on one column for the IR if you add "IR_" before the column name, then call the url with this column as an parameter.
    Example. You have an application page with a IR on it that you call like this (page 5):
    http://myapex:7777/pls/apex/f?p=&APP_ID.:5:&APP_SES.::NO:::
    The IR has a column ENAME wich is shown as eployee name (report heading).
    To set a filter ENAME='SMITH' this you call the page like this:
    http://myapex:7777/pls/apex/f?p=&APP_ID.:5:&APP_SES.::NO::IR_ENAME:SMITH
    Edited by: Sven W. on Apr 19, 2010 6:18 PM - added example
    If you want to set a different kind of filter. E.g. a ">=" search. Then you should go the way how dan explained. Create extra items for those filter criteria.
    Edited by: Sven W. on Apr 19, 2010 6:23 PM

  • Retrieve SQL with filters applied from an Interactive Report

    I want to use an Interactive report as interface for providing parameters to a base report query.
    I would like to capture the full SQL code from the filtered interactive report and then run the sql to create a collection.
    I have found this tread
    Re: Using Data from filtered Interactive Report
    which says that you can use APEX_APPLICATION_PAGE_IR to access the reports SQL. This holds the information about the interactive report when the user saves it. The sql code from the interactive report (after the user has added filters) is stored in the field sql_query.I can only retrieve the base query and not the filtered version even after saving.
    Any ideas how this can be done would be appreciated.
    regards
    PP

    OK Darren I think I've got it working. My solution is an adaption that follows the steps of a blog I found here: http://stewstools.wordpress.com/2009/02/19/get-ir-where-clause/
    My solution allows you to click on a button and the records that are currently displayed in the IR report are saved to an APEX collection. You can then use the collection to save records to a table or run a report on another page. (I haven't included code for this last step but it's easy to find on the forum)
    First a bit of background knowledge. The following APEX views hold all the information on IRs that you access via PLSQL code in the package you need to download. Run an IR report, save a version of the report, then in SQL Workshop have a look at:
    select * from APEX_APPLICATION_PAGE_IR
    select * from APEX_APPLICATION_PAGE_IR_COND
    select * from APEX_APPLICATION_PAGE_IR_COL
    select * from APEX_APPLICATION_PAGE_IR_RPT
    When you run an IR report it has an internal ID that you can access and also a Base Id for each Saved report that is currently in context.
    Here are the steps:
    1) Download the following package and install it in the workspace schema
    http://www.mediafire.com/?nj118x9vmc9
    click on the link "click here to download"
    2)In the HTML header Attribute of the page where your IR runs, put the following Javascript:
    <!--===================================================================-->
    <!--FUNCTION TO RETRIEVE IR REPORTS SQL WITH WHERE CLAUSE
    <!--===================================================================-->
    <script language="JavaScript" type="text/javascript">
    function SaveAndRunReport() {
    document.location='f?p=&APP_ID.:3:&SESSION.:CONSTRUCT_IR_QUERY:NO::'+
    'P3_BASE_REPORT_ID:'+$v('apexir_REPORT_ID');
    </script>
    <!--===================================================================-->
    Notes: You will need to obviously change the URL above to reflect your Page No. (3) and the name of a HIDDEN Item (P3_BASE_REPORT_ID) that you will populate with the base ID of the report.
    Setting :P3_BASE_REPORT_ID to +$v('apexir_REPORT_ID') is an internal thing and works out of the box. It returns the Id of the Base report.
    3) Create a button called SELECT_SPECIMENS (in region position - top of region) in the IR region that will initiate the execution of the IR background SQL to create a collection with the current selected records.
    TARGET= URL
    URL Target = javascript:SaveAndRunReport();
    You might also want to create a condition that only shows the button when there are records selected
    CONDITION TYPE=Exists(SQL returns at least one row)
    EXPRESSION 1 - put the SQL of the IR report here.
    4)Create a branch back to the same page (3) and with the REQUEST attribute set to the value in the Javascript URL above e.g. CONSTRUCT_IR_QUERY. Create a condition on the branch that uses this branch WHEN BUTTON PRESSED= SELECT_SPECIMENS
    5) Create an AFTER HEADER PROCESS with the following code:
    declare
    v_base_query clob;
    v_where clob;
    v_query clob;
    v_base_where varchar2(12):=' where 1=1 '; -- incase there is no where clause in the base query
    begin
    if apex_collection.collection_exists('IR_COLLECTION') THEN
    htmldb_collection.delete_collection( p_collection_name => 'IR_COLLECTION');
    end if;
    --GET THE BASE QUERY OF THE IR REPORT
    select sql_query
    into v_base_query
    from APEX_APPLICATION_PAGE_IR
    where application_id=:APP_ID
    and page_id=:APP_PAGE_ID; -- you can only have one IR report per page
    --UNCOMMENT TO VIEW THE PARAMETERS TO THE PACKAGED FUNCTION
    --raise_application_error(-20001, :APP_ID||'-'||:APP_PAGE_ID||'-'||:SESSION||'-'||:P3_BASE_REPORT_ID);
    --GET THE SQL FILTER CODE
    select apex_ir_query.ir_query_where(:APP_ID,:APP_PAGE_ID,:SESSION,:P3_BASE_REPORT_ID)
    into v_where
    from dual;
    --CHECK TO SEE THAT THERE IS A "WHERE" CLAUSE IN THE BASE QUERY
    if instr(upper(v_base_query),'WHERE ') > 0 then
    v_query:=v_base_query||' '||v_where;
    else
    v_query:=v_base_query||' '||v_base_where||' '||v_where;
    end if;
    --UNCOMMENT TO SEE THE FULL QUERY SYNTAX
    --raise_application_error(-20001,v_query);
    --CREATE COLLECTION FROM IR RECORDS
    apex_collection.create_collection_from_query(P_collection_name=>'IR_COLLECTION',p_query=>v_query);
    exception
    when others then
    raise_application_error(-20001, 'Interactive report not found. Contact Administrator. Could not create collection of records.');
    end;
    remember to update P3_BASE_REPORT_ID above to your HIDDEN ITEM name.
    Set the following attributes for the process above
    CONDITIONAL PROCESSING
    CONDITION TYPE = Request=Expression 1
    EXPRESSION 1 --> CONSTRUCT_IR_QUERY (Note: this was set on the branch in step 4 above)
    6) Run the IR report, click on the "SELECT SPECIMENS" button then click on the Session link on the Developer's Toolbar and select VIEW COLLECTIONS from the popup list then click GO. You should now see the IR records.
    By the way I've been testing in IE not Firefox.
    ...and that's it!
    enjoy
    Paul P

  • Interactive report pagination.

    Hi Folks,
               I have a interactive report page with 15 rows per page pagination.I browse to the 4 th segment of the report (i.e 46-60 rows) and moved out of the page through menu link. When I open that  IR page again it still in the  4 segment rather than first (i,e 1-15 rows). Is there any way change the pagination via page header to reset whenever I open the page.I tried all the option in the report pagination nothing works for me. Looking for guidance from you
    Thanks
    Karthik

    Hi Karthik,
    fac586 is correct.
    APEX URL Syntax: f?p=App:Page:Session:Request:Debug:ClearCache:itemNames:itemValues:PrinterFriendly
    I hope you are passing a URL link from java script in page1 and page2. You can pass RP in ClearCache section in that URL.
    for example, f?p=&APP_ID.:3:&APP_SESSION.:::RP:::
    If your IR is not based on any item values then you can create a Reset Pagination process. Refer the link 8.5 Understanding Page Processes.
    If possible share your java script where you are calling the IR page.
    Thanks
    Lakshmi

  • Custom pagination for APEX 4.2 interactive report using Page Zero

    Hi,
    I want to implement an «Custom pagination for APEX 4.2 interactive report» using a «page zero».
    I recently migrate from Apex 3.1 to Apex 4.2 and my «Custom pagination for APEX 3.1 interactive report» using a «page zero»  is not working any more.
    So now I try to adapt an excellent example of Jari Laine for 4.0 but using a page zero.
    I put the code JavaScript to Page zero but I must create an dynamic action to fire only for an interactive report region.
    It’s a good idea?
    Thank you

    Thought I would try once more with my DatePicker question.
    On the Apex.Oracle.Com website I have created a 1 page application that has an Interactive Report.
    [url http://apex.oracle.com/pls/apex/f?p=15655:1]
    user = 'test'
    password = 'test'
    I have 2 questions :
    (1) In IE7, press 'Actions', 'Filter'. On the Column dropdown list, select 'Order Timestamp'.
    Notice the prompt icon to the right of the 'expression'. This should change to the Datepicker, but in IE7 it does not. Try the samething in Firefox or Chrome and the Datepicker will appear.
    Is this a BUG, or does Apex 4.02 not support IE7 ?
    (2) In Firefox or Chrome, where you can now see the Datepicker, you will notice that it is the new style picker, not the old style ( called 'classic' ). I want to change it so that it shows the 'classic' datepicker not the new, but cannot see how to do it, if indeed you actually can.
    I would really appreciate it if someone could take a look and let me know if I am going mad, or if we need to get all our users onto IE8. We have now gone live with Apex 4.02 and need to resolve these issues.
    Thanks in advance.
    Edited by: DooRon on 10-Mar-2011 05:13

  • Interactive report performance problem over database link - Oracle Gateway

    Hello all;
    This is regarding a thread Interactive report performance problem over database link that was posted by Samo.
    The issue that I am facing is when I use Oracle function like (apex_item.check_box) the query slow down by 45 seconds.
    query like this: (due to sensitivity issue, I can not disclose real table name)
    SELECT apex_item.checkbox(1,b.col3)
    , a.col1
    , a.col2
    FROM table_one a
    , table_two b
    WHERE a.col3 = 12345
    AND a.col4 = 100
    AND b.col5 = a.col5
    table_one and table_two are remote tables (non-oracle) which are connected using Oracle Gateway.
    Now if I run above queries without apex_item.checkbox function the query return or response is less than a second but if I have apex_item.checkbox then the query run more than 30 seconds. I have resolved the issues by creating a collection but it’s not a good practice.
    I would like to get ideas from people how to resolve or speed-up the query?
    Any idea how to use sub-factoring for the above scenario? Or others method (creating view or materialized view are not an option).
    Thank you.
    Shaun S.

    Hi Shaun
    Okay, I have a million questions (could you tell me if both tables are from the same remote source, it looks like they're possibly not?), but let's just try some things first.
    By now you should understand the idea of what I termed 'sub-factoring' in a previous post. This is to do with using the WITH blah AS (SELECT... syntax. Now in most circumstances this 'materialises' the results of the inner select statement. This means that we 'get' the results then do something with them afterwards. It's a handy trick when dealing with remote sites as sometimes you want the remote database to do the work. The reason that I ask you to use the MATERIALIZE hint for testing is just to force this, in 99.99% of cases this can be removed later. Using the WITH statement is also handled differently to inline view like SELECT * FROM (SELECT... but the same result can be mimicked with a NO_MERGE hint.
    Looking at your case I would be interested to see what the explain plan and results would be for something like the following two statements (sorry - you're going have to check them, it's late!)
    WITH a AS
    (SELECT /*+ MATERIALIZE */ *
    FROM table_one),
    b AS
    (SELECT /*+ MATERIALIZE */ *
    FROM table_two),
    sourceqry AS
    (SELECT  b.col3 x
           , a.col1 y
           , a.col2 z
    FROM table_one a
        , table_two b
    WHERE a.col3 = 12345
    AND   a.col4 = 100
    AND   b.col5 = a.col5)
    SELECT apex_item.checkbox(1,x), y , z
    FROM sourceqry
    WITH a AS
    (SELECT /*+ MATERIALIZE */ *
    FROM table_one),
    b AS
    (SELECT /*+ MATERIALIZE */ *
    FROM table_two)
    SELECT  apex_item.checkbox(1,x), y , z
    FROM table_one a
        , table_two b
    WHERE a.col3 = 12345
    AND   a.col4 = 100
    AND   b.col5 = a.col5If the remote tables are at the same site, then you should have the same results. If they aren't you should get the same results but different to the original query.
    We aren't being told the real cardinality of the inners select here so the explain plan is distorted (this is normal for queries on remote and especially non-oracle sites). This hinders tuning normally but I don't think this is your problem at all. How many distinct values do you normally get of the column aliased 'x' and how many rows are normally returned in total? Also how are you testing response times, in APEX, SQL Developer, Toad SQLplus etc?
    Sorry for all the questions but it helps to answer the question, if I can.
    Cheers
    Ben
    http://www.munkyben.wordpress.com
    Don't forget to mark replies helpful or correct ;)

  • Interactive report run pl/sql by clicking on link column

    Hi!
    How can I run pl/sql script by clicking on a link column of an interactive report?
    Andras

    EDIT : Oh sorry don't saw the date, I'm a little late...
    Hi,
    if you want a link for each row, an other solution is to include the link column in your query, which would be more customizable, ie :
    select
    COLUMN1,
    COLUMN2,     
    '<ahref="f?p=&APP_ID.:6:&APP_SESSION.::NO::" onclick="your_function('||YOUR_ID_COLUMN||');return false;">link or picture</a>' as "link",
    COLUMN3;
    from
    ...As you see, you will have to include the ID (primary key) column to your report ("hidden") to identify the row clicked when calling your function.
    If you want to use the Link Column property in the report attributes, you will have to call you js function in the "URL" field like that :
    javascript:your_function('#YOUR_ID_COLUMN#');
    Yann.
    Edited by: Yann39 on 17 sept. 2010 02:41

  • Remove HTML from Interactive report download

    I have interactive reports where the column link on a specific column has to be dynamic, that means, it cannot be hard coded in the column link attributes. The following is an example of one such report query:
    case when d.object_type_description ='Business Service' then
    '< href="f?p='||:app_id||':183:'||:app_session||'::::P183_OBJECT_ID:'||d.id||'">'||d.object_name||'</>'
    when d.object_type_description = 'Real Time Event' then
    '< href="f?p='||:app_id||':162:'||:app_session||'::::P162_OBJECT_ID:'||d.id||'">'||d.object_name||'</>'
    else
       null
    end as "OBJECT NAME"As you see in the above example, the link on the "Object Name" column could either redirect to page 183 or to page 162 based on the "Object Type Description" column.
    The column attribute of the "Object Name" column has "Display Type" set to "Standard Report Column". That works perfectly fine in the UI of the report. However, if I download the IR data (in any format) from the Actions -> Download menu, the object name column values are downloaded with the HTML characters as:
    < href="f?p=15548:183:6072319179284::::P183_OBJECT_ID:255245470513999672860510787772603748464">JP010000</>where JP010000 is the object name.
    Is there a way I can strip the HTML from the column values in the downloaded files?
    I am using Apex 4.1.

    Rohit,
    You can define the link in the query, make it hidden, use the value as column link URL. So, your query will look like the following:
    d.object_name,
    case when d.object_type_description ='Business Service' then
        'f?p='||:app_id||':183:'||:app_session||'::::P183_OBJECT_ID:'||d.id
    when d.object_type_description = 'Real Time Event' then
        'f?p='||:app_id||':162:'||:app_session||'::::P162_OBJECT_ID:'||d.id
    else
       null
    end linkChange the display type of LINK column to Hidden. In column link, enter #OBJECT_NAME# as Link Text. Select URL as Target. Enter #LINK# as URL value. In APEX 4.2, you can do this in easier way by defining HTML Column Expression.
    Regards,
    Christina
    Edited by: cbcho on Sep 27, 2012 11:35 AM

Maybe you are looking for