Show / Hide DOWMLOAD link in classical report based on user rights

Hi,
using apex 4.1.
How i can display or hide download link in classical report based on user rights .
The User who has download rights ,can download the data from classical report Otherwise it should hide.
I have passed the code in authorization scheme in shared component as named "VIEW"
DECLARE
VNAME VARCHAR2(1000);
BEGIN
SELECT PAGE_NAME INTO VNAME FROM APEX_APPLICATION_PAGES WHERE PAGE_ID = :APP_PAGE_ID AND APPLICATION_ID = :APP_ID;
return GET_ADMIN_STATUS_VIEW_NEW(:APP_USER,VNAME);
END;How i can call "VIEW'' name in download link.

Right click on the export link, select copy url. Create a button with redirect to URL. Use that URL (or at least everything with and after f?p). Bind rights to the button.
Or create a second identical report with different rights, give one export enabled and one disabled. The first is better, the second is easier :)
Edited by: Joni Vandenberghe on 8-feb-2013 5:08

Similar Messages

  • How to get folder/webi reports based on user rights in BOX3.1

    Hi ,
    We are using java SDK to interface with BOXI3.1.In our project users will login through J2EE Screen after login users  needs to see what are webi reports they are having access.
    It is very greatful for me if you provide sql query/java code to get reports based on access.
    Thanks,
    Subash

    first of all with your user previllages you can test which folders or reports can be seen at http://[SERVERIP]:[PORT]/AdminTools/ web application. After login process you can prepare a query or you can try "SELECT * from CI_INFOOBJECTS WHERE SI_KIND='Folder' " with this query you can see a list of folders for the user who you logged the application.
    For java samples code I can send in a one or two days

  • Refresh classic report based on select list value selected

    hello,
    can anyone please help me out with this issue. I have a parameterized classic report based on a select list and I want to refresh this report whenever the select list value is changed. I am using oracle apex version 3.2. i just want to have a javascript function onchange event for the select list which refreshes my report whenever a value is selected.
    My select list item is p1_datastore
    select distinct datastore d,datastore r from my_table1 order by 1;
    My classic report query is
    select * from my_table2 where datastore = :p1_datastore order by last_updated_dt desc;
    ****************************************************thanks,
    orton

    can anyone please help me out with this issue.
    thanks,
    orton

  • Hide logout link in interactive report

    Hi,
    Can anyone tell how to hide logout link in interactive report?
    Thanks,

    Hi,
    Sorry, I do not understand question.
    How you did get logout link to interactive report ?
    I have never seen that logout link is generated to report automatically.
    But id you go
    Home>Application Builder>Application xxx>Shared Components>Navigation Bar Entries
    and edit your logout link, you can set condition witch page you like it to be displayed or not to be.
    I think you mean that one
    Br, Jari

  • How to Generate a Report Based on User's Parameters from Web Site

    Hi, all,
    I am trying to use Oracle Developer 6.0 Report Builder to generate report based on what user types in from the web site. Since I am a novice, I am wondering if anybody would help me with the following questions:
    1. How can I create a report based on user's parameters?
    Assuming that I have 2 text fields EMPNO and DEPT on the web site, after user types in some value, how can I pass these parameters into my query, can I do something like:
    select ENAME, JOB, EADDRESS from EMP
    where EMPNO =
    some_reference_of_parameters_from_user
    or is there any other way to achieve this functionality?
    2. How can I pass a PDF format report back to user after the report is generated?
    Any help is greately appreciated!!
    Best regards.
    Judy

    Hello,
    In the Report Builder, create two user parameters, and set the parameter name, datatype, width, and default values to what you want. Modify the query and put in a where clause (e.g., where deptno = :p_deptno). When you request the report with PARAMFORM=YES on the URL, it'll generate a default parameter form in HTML and allow the user to enter in the selected parameter values. Also set DESTYPE=CACHE&DESFORMAT=PDF on the URL to get the output back as PDF.
    If you upgrade to Reports 6i, you can customize the default HTML parameter form.
    Regards,
    The Oracle Reports Team --skw                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • How to show/hide a link column in a report, depending on another column?

    Sorry, thread duplicated.
    Edited by: Andres Vilallave on 14-may-2010 15:31

    Hello,
    I had a situation similar to this. I had NULL selected in the column when I wanted to hide the link. Please find below more explenation:-
    <b>example report </b>
    Interactive Report
    Col1     col2     col3
    1          a1       a2
    2          b1       b2
    -           c1       c2
    -           d1       d2
    -------------------------------------------In the above Report <b><i>col1</i></b> is a link . Upon clicking this, user should will be directed to Page XX
    so, when data in col2 of report is c1 or d1[can be a different display condition, you may want to implement this with CASE or anyother SQL construct] , I selected NULL which will not show the link.
    so, my point is, if the SQL you have in the INTERACTIVE REPORT is creative enough to have NULL in the column, Link is not enabled.
    Hope I got your problem correct.
    Thanks,
    Chaitu.

  • How to color single column cells with different colors in classic report based different conditions

    Hi ,
      Am working on Oracle Apex 4.2 version. Am trying to generate a  classic report with different cell colors based on the conditions.
      I tried the solution provided in the below link.
      https://forums.oracle.com/message/9518723#9518723.
      I tried the same query given in that link.
       SELECT e.*,
      CASE
        WHEN sal < 1000
        THEN 'red'
        WHEN sal BETWEEN 1000 AND 2000
        THEN 'yellow'
        WHEN sal > 2000
        THEN 'green'
      END the_color
    FROM emp e
      And, I hidded the column 'the_color' in Report Attributes,
              the Column Template1 has the code , <td #ALIGNMENT# headers="#COLUMN_HEADER_NAME#">#COLUMN_VALUE#</td>.
    After this, what are the steps did I miss here. Because am not getting the report which I need.
    Kindly do provide solution.
    Thanks,
    yashu.

    SAL column values should visible with different color based on the conditions. Same way i did in my report it was working for me. Please refer the below links for more information,
    https://forums.oracle.com/thread/1047891
    http://dbswh.webhop.net/htmldb/f?p=BLOG:READ:0::::ARTICLE:351800346145832
    Thanks
    Lakshmi

  • No data found when adding column link to classic report

    Hi,
    Oracle 11g r2, APEX 4.1.1.00.23.
    I have some classic reports.
    I go to Report Attributes, then I click Add Column Link in the "Tasks" right menu, it adds me a column link, I just add some text for the link and a page to go to.
    Then I run the report and I get :
    report error:
    ORA-01403: no data foundTested with several classic reports on multiple pages.
    Debug mode shows me :
    0.43816     0.00240     ...Execute Statement: select distinct [...] order by 3,11 ,4
    0.44056     0.00162     print column headings
    0.44218     0.04816     rows loop: 25 row(s)
    0.49037     0.00141     report error: ORA-01403: aucune donnée trouvée
    0.49175     0.00078     Computation point: After Box BodyWhen I run the query in my favorite tool, I get expected results.
    Did I missed something ?
    Thank you.
    Yann.

    Yann39 wrote:
    <font size="4">Is it an APEX bug ?</font>
    - Create a new Region of type Classic Report, then set Region source as :
    begin
    return test_return_query;
    end;- Run the page, the report works as expected
    - Go to Report Attributes and click Add Column Link (and just specify a text for the link and a page to go to).
    - Run the page, you should get the error !This might be unorthodox but try wrapping your returned query within an SQL statement, like so:
       begin
          return 'SELECT t.* FROM ('||test_return_query||') t';
       end;
    I can reproduce it on oracle.apex.com if needed...If my suggestion doesn't work, I think this might be the only option. You could create a new forum posting with the word "BUG" in the title, along with a link to this thread and the relevant workspace details (with guest developer credentials).

  • How to show the columns dynamically in OBIEE report based on the selection?

    Hi,
    I have a requirement where the columns should be dynamically shown in report based on what we select in propmt page.
    I'm creating a report in OBIEE where i want to give an option to the end user to select the columns whichever he wants to see in the report.
    For example I have the following columns in the report already:
    Customer Name,
    Customer Number,
    Bank Account,
    Address
    I want to give an option to the user to select 'Customer Mail ID' dynamically and see the column to be displyed in the report along with the existing columns.
    Through 'Column Selector' user can select a single column at a time, but if he want to select more than one column, how can we do this ?
    Please help me out in resolving this issue.
    Thanks,
    Chaithanya.

    Hi Chaithanya,
    there's not a straight solution for this. You can create different analysis containing different number of columns and then directing the user to this analysis using Action Links or you can also use View Selector to switch from one view (analysis) to the other. But it's not going to be very flexible nor dynamic.
    J.

  • Bug in Classic Report based on Function?

    As a simple example, suppose I want a classic report in which I can change the sort field by selecting from the item P1_SORTFIELD. In Apex 4.2 I was able to implement the report using the PL/SQL function
    return 'select ENAME, SAL from EMP order by ' || :P1_SORTFIELD;
    I cannot do this in Apex 5 on my apex.oracle.com workspace. I either get an "SQL command not property ended" runtime error if I use generic column names, or "not all variables bound" parse error if I don't.
    My real application uses generic column names, so I am most interested in a solution to that.  For example, I tried creating a report having the source
    return 'select ENAME from EMP order by ENAME';
    If I run it using generic column names I still get the "SQL Command not properly ended" runtime error.
    Is this a bug??
    Ed Sciore

    Ed Sciore wrote:
    As a simple example, suppose I want a classic report in which I can change the sort field by selecting from the item P1_SORTFIELD. In Apex 4.2 I was able to implement the report using the PL/SQL function
    return 'select ENAME, SAL from EMP order by ' || :P1_SORTFIELD;
    I cannot do this in Apex 5 on my apex.oracle.com workspace. I either get an "SQL command not property ended" runtime error if I use generic column names, or "not all variables bound" parse error if I don't.
    My real application uses generic column names, so I am most interested in a solution to that.  For example, I tried creating a report having the source
    return 'select ENAME from EMP order by ENAME';
    If I run it using generic column names I still get the "SQL Command not properly ended" runtime error.
    I cannot reproduce the same error messages in my workspace on apex.oracle.com.
    The basic problem here is that the function body will not return a syntactically correct SQL query if the session state value of P1_SORTFIELD is not a valid sort expression for the query. This will always be the case when the region source is validated in the App Builder, and also if P1_SORTFIELD is null at runtime. The solution is to ensure that the function body always returns a valid query irrespective of the value of P1_SORTFIELD:
    return 'select ENAME, SAL from EMP' || nullif(' order by ' || :p1_sortfield, ' order by ');
    Here is another weird thing. I looked at my Apex 4.2 application that got transferred over to Apex 5. The region that does the dynamic sorting still works. But now I just created a new region on that page that has the same source, and as far as I can tell, exactly the same properties. And this region gives me the runtime error. The URL is apex.oracle.com/pls/apex/f?p=80034:33 if that helps.
    Given that I can't reproduce your results based on the information provided, I think we'd need access to the app in your workspace in debug mode to investigate this fully.

  • Highlight  a row in classic report based on condition

    HI all Gurus
    Using Apex 4.1.1 oracle 11g linux oc4j
    I want to highlight a row where #column_value#='Y' to grey  keep others as normal report settings.
    I have a simple sql query
    SELECT PK_ID,
      FIRST_NAME,
      LAST_NAME,
      INITIAL_REG_DATE,
      MAIL_DATE,
      BEGIN_DATE,
      END_DATE,
      END_DATE-BEGIN_DATE as "#days",
      BEGIN_STATUS,
      END_STATUS, 
      COMMENTS,
      DELETE_FLAG,
    case when  DELETE_FLAG='Y' then 'GREY' else '#f0f0f0' end  DELETE_FLAG ,
    INITIAL_REG_DATE+(END_DATE-BEGIN_DATE) "New Reg end date"
    FROM SOR_TRACKING_DEL
    where pk2_id =:P216_Detail
    order by mail_Date desc
    I created a Dynamic action
    which will fir on on load , BIND on this classic report
    $("input[name=f29]").each(function(){ 
    var lThis=$(this); 
    if(lThis.is("Y")){ 
      lThis.parents("tr:eq(0)").children("td").css({"background-color":"GREY"}); 
    } else { 
      lThis.parents("tr:eq(0)").children("td").css({"background-color":"#f0f0f0"}); 
    But this is not changing color as expected..
    Kindly help me !
    Thanks

    Scott and Tom
    Thanks you guys for looking into this.
    Pls ignore my improper explanation and my inexperience with jquery.
    I read some blog and was trying to do same on classic report but all blogs I found so far referred either interactive report or tabular report none of them mentioned classic report.
    I guess using array for classic report wont be a good idea to start with. :/
    I am not sure if this is right syntax and logic to highlight the row
    $(function(){
    var DELETE_FLAG = $(this);
        if DELETE_FLAG.is("Y"))
      DELETE_FLAG.parents("tr").children("td").css({"background-color":"GREY"});
    I also created app here
    http://apex.oracle.com/pls/apex/f?p=35155
    workspace sors
    user tester/testing
    application 35155
    Thanks again.

  • OBIEE 11g - Formatting a dahboard/report based on users

    Hi All,
    Could someone please tell me if it is possible to format a report based on different users so that when User1 logs in and clicks Report1, then he/she can view the data with Format1 (lets say value is bold, with green colour in background etc) whereas when User2 clicks Report1, then he/she can view the same data but with Format2 ( value not in bold, with blue colour in background etc).
    I am not sure if we can do something with CSS styling based on users.
    Thanks,
    Sneha

    Hi Sneha,
    Try to use Conditional Formatting.
    1> Pull one extra column in your report along with required columns in report.
    2> In that extra column in fx put user();
    3> In the column where you want bold and background color based on user, set conditional format (Add condition extra column = A, then Bold and BG Color).
    4> Hide that extra column.
    Please let me know whether it resolves your issue.
    Thanks
    Anirban

  • Creating report based on user selected Date Range

    Hello.
    I am trying to display an Apex report that selects data for the report based on a user entered date range.
    It's a simple page with two date picker fields (p18_start and p18_end).
    The report region SQL looks like this:
    SELECT *
    FROM prj_items
    WHERE LM_DT BETWEEN :p18_start AND :P18_end
    One table, one field on the table to search and two Apex variables.
    I thought this would be fairly simple, but I am obviously missing something.
    I not even sure what other information is needed to help me figure this out.
    -Jody

    Hi,
    You can set defaults for the datepickers if you need to - this could be done in a computation on the page for each item and conditional on the item being null.
    When I've done something similar to this, I've created two hidden page items - eg, :P19_FIRST_DATE and :P19_LAST_DATE and populated these with the earliest/latest date that the user could reasonably select (perhaps, in your case, the MIN(LM_DT) and MAX(LM_DT) values).
    Then your SQL would be:
    select * from PRJ_ITEMS
    where LM_DT BETWEEN TO_DATE(NVL(:P19_START,:P19_FIRST_DATE), 'DD-MON-YY')
    AND TO_DATE(NVL(:P19_END,:P19_LAST_DATE), 'DD-MON-YY')If you don't want to set default dates, you could do something like:
    SELECT * FROM PRJ_ITEMS
    WHERE (:P19_START IS NULL AND :P19_END IS NULL)
    OR (:P19_START IS NOT NULL AND :P19_END IS NULL AND LM_DT >= TO_DATE(:P19_START,'DD-MON-YY'))
    OR (:P19_START IS NULL AND :P19_END IS NOT NULL AND LM_DT <= TO_DATE(:P19_END,'DD-MON-YY'))
    OR (LM_DT BETWEEN TO_DATE(:P19_START,'DD-MON-YY') AND TO_DATE(:P19_END,'DD-MON-YY'))There are various reasons why your two dates are being cleared when the page is reloaded. Firstly, you should check the branch that returns to the same page - make sure you are not clearing the cache for the page. Then, have a look to see if there is a "reset page" process (usually created for you when you create a form page). Then, check the Source settings for the items. Typically, these would be "Only when current value in session state is null" and a Source Type of "Static Assignment" with the "Source Value or Expression" left empty.
    Andy

  • Filter standard reports based on user login

    Hi All,
    Is there any way to filter standard form reports (not PLD), based on the user currently logged in. for example, if user 'sales1' has logged in,  he should be able to see the sales report(say sales analysis) for the documents made by him only. there does not seem to have any access on the query being passed to this report. so even customization does not seem to be the solution. kindly help if any one knows a better way or a way at all.
    thnks and regards,
    Binita Joshi

    Hi Petr,
    thanks for replying.
    Before posting, I had already searched in SAP B1 forum and there , for a similar problem, it was advised to use SDK so I posted here.
    I knew, SDK seems to be the way. but, again, As I wrote, I wanted to know, whether there exists a way to filter the standard reports based on the user login. I don't want authorization or setting rights, sort of things.
    but, suppose If user A wants to see the sales documents reports then, he should be able to see the reports of the documents made by him only. so we will have to filter the records based on the Usersign field in marketing documents' tables but, I am clueless on, where should I give this filter.  and I am afraid there is no way to do that. make your own reports and block the access of system reports.Pls right back if U have more to say.
    regards,
    Binita Joshi

  • More/Less link to show & hide more text in a report

    Hi Everyone,
    Lot of my reports having description field running around close to 100 to 200 characters.
    So instead of showing all the description to the users why not show only partial data like first 100 characters and then followed with a "More..." link to show the rest and change the link to "...Les".
    On clicking Less it should display only 100 characters.
    Can some one please throw some light on how to embed this in a report column.
    Thanks,
    Teku.

    Hi,
    Lot of my reports having description field running around close to 100 to 200 characters.So instead of showing all the description to the users why not show only partial data like first 100 characters and then followed with a "More..." link to show the rest and change the link to "...Les".
    On clicking Less it should display only 100 characters.
    Can some one please throw some light on how to embed this in a report column.>
    Tweak your report query
    SELECT ...
    '<div id="less_#ROWNUM#">'||substr(Long_column,1,100)||'<a ref="javascript:$x_Show(''more_#ROWNUM#'' );
        $x_Hide(''less_#ROWNUM#'');">more...</a></div><div id="more_#ROWNUM#" style="display:none;">'||
        Long_column||'<a ref="javascript:$x_Show(''less_#ROWNUM#'' );$x_Hide(''more_#ROWNUM#'' );">
        ...less</a></div>'  LongColumn
    ...FROM...Replace ref with href, I had to remove the leading h to post the code snippet.
    Next create a function that accepts varchar2 as input and returns the HTML fragment as shown above, say do_more_less . In all your report queries call the function , e.g.
    SELECT ... , do_more_less(Long_column) LongColumn, ...Cheers,

Maybe you are looking for