Custom report based on function returning cursor

Hi,
I'm trying to create a generic function that will be the basis of a custom report in Grid Control.
The idea is to pass in a database link name, then the function builds a cursor to select using that name, and returns the result to Grid control to render.
At the moment all I get is an empty table.
My function is defined as follows:
create or replace function list_databases(p_dblink varchar2) return sys_refcursor
is
db_name varchar2(40);
c_cursor sys_refcursor;
v_query varchar2(100);
begin
v_query := 'select name from rc_database@'||p_dblink;
open c_cursor for v_query;
return c_cursor;
end;
The custom report contains a 'Table from SQL' type, with the following sql statement:
select sysman.list_databases('rmancat_test') from dual
I've tried playing around with the ??EMIP_BIND_RESULTS_CURSOR?? bind variable but it only seems to work if I write the pl/sql block in the custom report, rather than going for a generic function.
Any ideas are most welcome.
Chris

Why not use a simple procedure to achieve the same thing?

Similar Messages

  • Report based on function returning query

    Hi all,
    I created a function FCT_1 in a package PKG, here is an exemple :
    function FCT_1(te in number) return varchar2
    is
    q varchar2(4000);
    begin
    if te = '1' then
    q := 'Select * from Clientele';
    else
    q := 'Select * from Compagnie';
    end if;
    return q;
    end;
    And I call this function the region source of my report like this :
    Declare
    q varchar2(4000);
    Begin
    q:=PKG.FCT_1(:P2_Nb); -- P2_Nb = 1 or 2
    return q ;
    end;
    But I got this error :
    report error:
    ORA-01403: no data found
    I need your help.
    Benn

    I got it,
    I just use the Use Generic Column Names (parse query at runtime only) option.
    I don't know why do I have to do it.
    Thanks
    Benn

  • Custom reports in R12 not returning any data

    I'm seeing an issue of custom reports in R12 not returning any data. So far what I've been able to dig into is that the report query itself is referring to APPS synonyms that are secured under MOAC. What I am able to do is run the query in SQL Developer after having run mo_global.set_policy_context and I receive the data I'm looking for. This is not the case when running the report through the concurrent programs request.
    Secondly, I've also configured the concurrent program request to run as single operating unit mode. This aided in fixing any issues with LOVs on the parameter form. However, still no results from the report itself. I've also searched around quite extensively and added a P_CONC_PROGRAM_ID user parameter in reports developer, as well as adding SRW.USER_EXIT('FND SRWINIT') to the before report trigger and SRW.USER_EXIT('FND SRWEXIT') to the after report trigger as well. No luck. I've also tried running mo_global.set_policy_context on the before report trigger and no such luck.
    Has anyone seen similar issues with this and could shed some light? At this point, the workaround I would see is to just change the query to use respective all tables and match up against the orgid, but I'd rather not do that.

    I am facing exactly the same issue with 2 of my custom Reports in R12.1.3. We did our level best to find out the issue. It was always a hit and trial fix.
    But the following were our observations and workarounds
    0) The reports Conc Prog were in MOAC - Single mode. Both the reports had SRW INIT, EXIT and P_CONC_REQUEST_ID
    1) The reports which caused the issues[NO data fetched for MOAC] had multiple Queries in the data model and one Query fetches data and the 2nd one doesnt. Both the queries when run from SQL developer after setting the org gave results.
    Workaround for Report1
    a) We deleted the data link connecting the 2 columns in both the queries and added a bind variable instead in the 2nd /child query to refer to the column in the parent query and linked the 2 groups.
    Workaround for Report 2
    a) In report 2 the queries were not linked to each other. Only one query used to return results and the 2nd one returned 0 rows. The workaround was to use the "where" conditions as lexical parameters after having set the value for the same in before report trigger.
    Both the work around looks illogical. Still It worked..!
    Thanks
    Biju Radhakrishnan

  • List of customer report based on account group - T.Code

    Dear Guru's
               I need list of customer report based on account group in standard SAP if it there please update th T.Code as earl as possible.
    regards,
    bhanu

    Hello,
    I don't think there is a standard report for this. SE16 select table KNA1 and check for the entries with respect to account group.
    Prase

  • On Submit process not firing -report (PL/SQL function returning SQL query)

    Can anyone suggest possible causes / solutions for the following problem?
    I have a report region that uses a PL/SQL function returning SQL query. The report allows the user to update multiple fields / rows and then click a button to submit the page which should run the On-Submit process to update the database. However the process does not run and I get a 'HTTP404 page cannot be found' error; and when I navigate back using the Back button I cannot then navigate to any other page in my application without getting the same error. The button was created by a wizard selecting the options to submit the page and redirect to a (same) page. The button does not actually have a redirect in its definition but the wizard created a branch to the same page which should work and the button has the text 'submit as SUBMIT' next to it so it appears to be set up correctly.
    I have recreated this page several times in my application and I cannot get the On-Submit process to run. However I have created a cut down version of the same page in the sample application on apex.oracle.com at http://apex.oracle.com/pls/otn/f?p=4550:1:179951678764332 and this works perfectly so I am at a loss to understand why it does not work in my application. I cannot post any part of the application itself but if anybody would like to check out page 30 of the sample application (Customer Update Test tab) updating the surnames only, using credentials ja, demo, demo this is pretty much what I have got in my application.
    Any ideas would be much appreciated?

    Thanks for the suggestions guys. I have now identified that the problem goes away when I remove the second table from my report query. The original report query retrieved data from two tables and the process was updating only one of the tables. I thought I had approached the task logically i.e. first get the report to display the records from the two tables, then get the process to update the first table and finally to modify the process further to update the second table.
    Can anyone point me to an example of multiple row updates on multiple tables using a PL/SQL function returning an SQL query?

  • 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.

  • Report- Pl/sql function returning sql query parsing page items as text?

    Hi Team,
    I am facing a strange issue .
    I have four page items namely
    1)JOB_CODE
    2)MIN_EXP
    3) MAX_EXP
    4) SOURCES1
    I have a report of the type "Pl/sql function returning sql query"
    declare
    v_sql varchar2(4000);
    begin
    if (:JOB_CODE IS NOT NULL and :MIN_EXP IS NOT NULL and :MAX_EXP IS NOT NULL and :SOURCES1 IS NOT NULL) then
    v_sql:= 'select v_candidate_id, v_fname,v_current_employer,v_Experience_years from candidature where V_REQUIREMENT = :JOB_CODE and v_experience_years >= :MIN_EXP and v_experience_years <= :MAX_EXP and source like ' || '''' || '%'|| ':SOURCES1' || '%' || '''';
    elsif (:JOB_CODE IS NULL and :MIN_EXP IS NOT NULL and :MAX_EXP IS NOT NULL and :SOURCES1 IS NOT NULL) then
    v_sql := 'select v_candidate_id, v_fname,v_current_employer,v_Experience_years from candidature where v_experience_years >= :MIN_EXP and v_experience_years <= :MAX_EXP and source like ' || '''' || '%'|| ':SOURCES1' || '%' || '''';
    elsif (:MIN_EXP IS NULL and :JOB_CODE IS NOT NULL and :MAX_EXP IS NOT NULL and :SOURCES1 IS NOT NULL) then
    v_sql := 'select v_candidate_id, v_fname,v_current_employer,v_Experience_years from candidature where v_experience_years <= :MAX_EXP and V_REQUIREMENT = :JOB_CODE and source like ' || '''' || '%'|| ':SOURCES1' || '%' || '''';
    elsif (:MAX_EXP is null and :JOB_CODE IS NOT NULL and :MIN_EXP IS NOT NULL and :SOURCES1 IS NOT NULL) then
    v_sql := 'select v_candidate_id, v_fname,v_current_employer,v_Experience_years from candidature where V_REQUIREMENT = :JOB_CODE and v_experience_years >= :MIN_EXP and source like ' || '''' || '%'|| ':SOURCES1' || '%' || '''';
    end if;
    insert into query_list values (v_sql);
    insert into debug values (:JOB_CODE , :MIN_EXP , :MAX_EXP , :SOURCES1);
    return v_sql;
    end;
    Please not that I am insertin the query into a table called Query_list and the page item values into the table called Debug thru the pl/sql function which returns teh query.
    Now I select the data from the debug tables.
    select unique(query) from query_list;
    select v_candidate_id, v_fname,v_current_employer,v_Experience_years from candidature where V_REQUIREMENT = :JOB_CODE and v_experience_years >= :MIN_EXP and v_experience_years <= :MAX_EXP and source like '%:SOURCES1%'
    select * from debug;
    JOBCODE     MINEX     MAXEX     SOURCE
    21     1     10     donkeyHire
    And if I run the query in sql I get some records returned
    select v_candidate_id, v_fname,v_current_employer,v_Experience_years from candidature where V_REQUIREMENT = 21 and v_experience_years >= 1 and v_experience_years <= and source like 'donkeyHire'
    V_CANDIDATE_ID     V_FNAME     V_CURRENT_EMPLOYER     V_EXPERIENCE_YEARS
    2     Vengu     Andale Tech     4
    But the record does not show up in the report!
    does this type of report parse page items as text?
    Why is it so?
    Waiting for an early reply.
    Thanks,
    venkat

    Venkat - You don't want to put ':SOURCES1' in quotes like that.
    Scott

  • Report based on PLSQL returning SQL query

    I created function which builds the SQL and returns it as VARCHAR2. For testing purposes I harcoded the primary ID for the query to be based on. I run the function as standalone call to get the generated SQL and to test it. It works fine. The moment I try to use the ID parameter as an argument passed to the function it doesn't work and I get the "No data found" error. Again if I try this function outside of Apex it produces correct SQL syntax and it runs.
    The function signature is really simple:
    FUNCTION abc(i_id NUMBER) RETURN VARCHAR2
    IS
    l_id NUMBER;
    BEGIN
    -- this works:
    -- l_id := 300;
    -- this doesn't work:
    l_id := i_id;
    ... more code follows. It uses the l_id while building the query.
    I also tried to make it an anonymous block and place it directly in Apex region. Again I face the same problem. I modified this function slightly to reference the page attribute instead of accepting parameter:
    DECLARE
    l_id NUMBER;
    BEGIN
    -- this works:
    -- l_id := 300;
    -- this doesn't work:
    l_id := :P65_ID;

    Have you verified that i_id and P65_ID have a value when the procedure runs? Perhaps have something along the lines of "if i_id is null then return 'select <dummy data> from dual' else [build real query here]"...?
    -D.

  • How to e-mail/not e-mail a scheduled report based on records returned

    Hi Everyone,
    Is there a way that there can be logic performed on a report that has been scheduled and ran before it gets sent via e-mail to the end users?  We have scheduled reports that often end up with 0 records returned but users still get the e-mail with the report that contains 0 records.  I would like to e-mail the reports only if the records returned is greater than 0.
    We are on v3.1 so if there is a solution for 3.1 that would be great.  If this capability exists in 4.0, that information would be very helpful as well.
    Thank you for your time.
    David Hellinger

    Apply an event on your report.
    First go to Cmc, create an event based for example on a file that should be created in certain route if the query won't return 0 rows.
    Then apply this event in your report Schedule option Event.

  • Function returning cursor..

    i have written a function which returns me a cursor ...
    CREATE OR REPLACE function getAdvisorInfo(advID IN char)
        RETURN types.ref_cursor
    AS
    atp_cursor types.ref_cursor;
    BEGIN
    OPEN atp_cursor FOR
        select ad.Advisor_id, ad.Bundle_code, bd.bundle_name, ad.platform,ad.position_code,ad.advisor_first_name,ad.advisor_last_name,ad.date_bundle_changed,ad.status from advisor_details ad,bundle_details bd where ad.bundle_code = bd.bundle_code and ad.advisor_id=advID;
    return atp_cursor;
    end getAdvisorInfo;it reads 2 tables as of now...
    1. advisor_details and values it reads from this table are ...
    a. advisor_id,
    b. bundle_code,
    c. platofmr,
    d. position_code,
    e. advisor_first_name,
    f. advisor_last_name,
    g. date_bundle_changed,
    h. status
    2. bundle_details ...and values it readds from this table are ...
    a. bundle_name.
    it works absolutely fine...
    now the value date_bundle_changed from advisor_details has to be read from a third table ...and to read that value i need a select query which is like ...
    SQL> select max(date_timestamp-0) from advisor_details_history where advisor_id=advID and date_timestamp between systimestamp-30 and systimestamp and change_reason='Bundle Selection';
    so in the query "select ad.Advisor_id, ad.Bundle_code, bd.bundle_name, ad.platform,ad.position_code,ad.advisor_first_name,ad.advisor_last_name,ad.date_bundle_changed,ad.status from advisor_details ad,bundle_details bd where ad.bundle_code = bd.bundle_code and ad.advisor_id=advID;" i need to replace that ad.date_bundle_changed with the above query ....which reads date_timestamp from a third table and then sets the value in this query itself...
    can some1 tell me how can i do this...or i need to use union only....:(
    is there any other way then union...
    please let me know..
    thank you..
    regards,
    chintan..
    let me know if i am not soo clear in conveying my problem...

    can some1 give me hint on how to do this..
    even with union i m struggling a bit... :(
    here is my function with union....but facing problems to form the query...
    CREATE OR REPLACE function getAdvisorInfo(advID IN char)
        RETURN types.ref_cursor
    AS
    atp_cursor types.ref_cursor;
    sqlQuery VARCHAR2(1000);
    changeReason VARCHAR2(30);
    BEGIN
    changeReason := 'Bundle Selection';
    sqlQuery := 'select ad.Advisor_id, ad.Bundle_code, bd.bundle_name, ad.platform,
                  ad.position_code,ad.advisor_first_name,ad.advisor_last_name,
                  ad.status, ad.date_bundle_changed from advisor_details ad,bundle_details bd where
                  ad.bundle_code = bd.bundle_code and ad.advisor_id=';
    sqlQuery := sqlQuery || 'advisor_id = '||CHR(39)||advID||CHR(39);
    sqlQuery := sqlQuery || 'UNION
             select ad.advisor_id, ad.bundle_code, bd.bundle_name, ad.platform,
                  ad.position_code, ad.advisor_first_name, ad.advisor_last_name,
                  ad.status, max(ad.date_timestamp-0) from advisor_details_history ad,
                  bundle_details bd where ';
    sqlQuery := sqlQuery || 'advisor_id = ' ||CHR(39)||advID||CHR(39) and ';
    sqlQuery := sqlQuery || 'date_timestamp between systimestamp-30 and systimestamp and ';
    sqlQuery := sqlQuery || 'change_reason = '||CHR(39)||changeReason||CHR(39);              
    OPEN atp_cursor FOR
         sqlQuery;   
    return atp_cursor;
    end getAdvisorInfo;
    ERROR:
    20/26    PLS-00103: Encountered the symbol "DATE_TIMESTAMP" when expecting
             one of the following:
             . ( * @ % & = - + ; < / > at in is mod not rem
             <an exponent (**)> <> or != or ~= >= <= <> and or like
             between ||
             The symbol "." was substituted for "DATE_TIMESTAMP" to continue.
    21/26    PLS-00103: Encountered the symbol "CHANGE_REASON" when expecting
             one of the following:
             . ( * @ % & = - + ; < / > at in is mod not rem
             <an exponent (**)> <> or != or ~= >= <= <> and or like
    LINE/COL ERROR
             between ||can some1 tell me what is the problem with the query ... ???
    thank you,
    Regards,
    Chintan

  • Function returning cursor to be used in select statement

    I have written a function which returns a cursor. I want to use this in a select statement to display rows. How to do this.
    Eg : function - test_fn return sys_refcursor. (returns empno, empname, deptname)
    select test_fn from dual
    This should return
    empno empname deptno
    1 name1 dept1
    2 name 2 dept2
    ....

    Try This::
    SCOTT@xe_144>variable c  refcursor
    SCOTT@xe_144>CREATE OR REPLACE FUNCTION get_nm
      2     RETURN sys_refcursor
      3  AS
      4    
      5     c sys_refcursor;
      6  BEGIN
      7    
      8     open c for 'SELECT ENAME , SAL FROM EMP';
      9      
    10     RETURN c;
    11  END;
    12  /
    Function created.
    SCOTT@xe_144>select get_nm into :c from dual;
    GET_NM
    CURSOR STATEMENT : 1
    CURSOR STATEMENT : 1
    ENAME             SAL
    SMITH             800
    ALLEN            1600
    WARD             1250
    JONES            2975
    BLAKE            2850
    CLARK            2450
    KING             3000
    AKASH2           5000
    TURNER           1500
    ADAMS            1100
    JAMES             950
    MILLER           1300
    ABC              2000
    13 rows selected.Let me know if its works for you.

  • Customized report based on data from 2 different infoproviders.

    Hi Team,
    The scenario is as follows:
    We have an Datasource based on a ECC Table which contains data based on FISCAL YEAR and no period field such as X03, X06 & X09. these values are populated in INFOCUBE A. Also note that the ECC table itself does not contain any field which refers to Period.
    In my another INFOCUBE B, I have the value for the Period (ZZPERIOD) field on a Quaterly basis.
    Now the report requirement is:
    For the input value of ZZPERIOD = 201103, display value X03.
    similarly for X06 and X09.
    PLEASE ADVICE.
    Thanks & Regards
    Sneha

    I'm not sure you've understood my reply. Do you understand the notion of granularity? If not please read about this and understand it. Then you will have the answer you need.
    I'm assuming you have KFs in both cubes right? Now if Cube A is aggregated by Year - you cannot split these figures by anything other than Year.
    Just because you want to add other key figures from another cube (B) whose values sit at Cal Quarter does not mean that any coded rules you apply will result in correct figures when you drill down to Quarter. How do you propose to fix that? Answer: you can't, it's impossible without getting yourself in a lot of trouble with the business/your client.
    Your best bet is to add a characteristic into Cube A called 'Source of Data' and fill that in your transformations. Then you can load both data from A and B into the same cube A. When reporting, just use a restricted KF to pull out the values you want.
    If you drill down by Quarter of course Cube A KFs will be "not assigned" for the simple reasons I explained above.

  • What is this message in report based on "return SQL"

    After changing some parameter value in one report based on "function return SQL body"", we get:
    Invalid set of rows requested, the source data of the report has been modified.
    reset pagination
    We get this notice without error....just link "reset pagination" (*http://server:port/pls/htmldb/f?p=100:203:2666560392386347:NO::RP) which leads to error:
    Error      No checksum was provided to show processing for a page that requires a checksum when one or more request, clear cache, or argument values are passed as parameters.
    Any help ?
    THX!
    Message was edited by:
    Funky

    Found out...
    Originaly one search field was POPUP LOV type. Later we change them to "Text Field", bud LOV definition remains ...regardles it points to LOV which was not in use now.
    When remove LOV reference and delete the definition ...all works like a charm...

  • Reports based on PL/SQL Procedure/Function

    Hi all,
    After some serious Google and forum searches, it appears as if this is something that just isn't possible (or easy to do).
    I've been charged with creating an APEX application that displays reports. There are a series of Procedures that will be written to return a result set, updated to take into account some filters that a user would provide. The key here is that the report won't be displayed until AFTER a user inputs some filters on a form and hits a Submit button. The project requires this functionality - allowing the report to be displayed and THEN filtered using the APEX IR Control is not desired (not my decision).
    There doesn't seem to be an easy way to define a report in this manner. It appears that the query for a report query needs to be known ahead of time.
    So, with that setup - is there a way to define an APEX report based on the return result of a PL/SQL function? OR is there a way to define a report using a SQL Query that is built based on user inputs?
    Any help would be appreciated.
    - Pedro

    Hi,
    Check if this post help you.
    Dynamic html table
    And normal reports can be also created from select that function is returning.
    http://www.oracle.com/technology/products/database/application_express/howtos/dynamic_report.html
    Br, Jari
    Edit:
    Maybe useful
    http://www.apex-blog.com/oracle-apex/dynamic-report-regions-tutorial-32.html
    http://www.oracleapplicationexpress.com/2009/02/interactive-report-based-on-plsql.html
    Edited by: jarola on Sep 9, 2009 5:14 PM

  • Report pl/sql function body returning query bind variable

    I really like using report with a function returning sql. I have been using something like this
    declare
    q varchar2(10000);
    begin
    q := 'select col1
    from mytable
    .... add a dynamic where clause ....
    return q;
    end;
    But I thought it would be nice to store the query in a bind variable so that I could show the where clause. I tried to create an item P123_Q and do the following:
    declare
    q varchar2(10000);
    begin
    q := 'select col1
    from mytable
    .... add a dynamic where clause ....
    :P123_Q := q;
    return q;
    end;
    But the parser treats :P123_Q as if it is a bind variable within flow 4000. I found a workaround but I'm wondering if there is a better way.
    My workaround is to set a preference in the query and then use a computation that sets P123_Q to the value of the preference:
    declare
    q varchar2(10000);
    begin
    q := 'select col1
    from mytable
    .... add a dynamic where clause l_q := l_q || ....
    HTMLDB_UTIL.SET_PREFERENCE(
    p_preference => 'Q',
    p_value => q,
    p_user => :APP_USER);;
    return q;
    end;
    Any thoughts on another way?
    thanks,
    Anton

    Anton,if htmldb_application.get_current_flow_sgid(:APP_ID) = htmldb_application.get_sgid then
      :P1_X := l_sql;
    end if;Scott

Maybe you are looking for

  • Setting up a Server for Small Network

    I have a workgroup of 3 people all on macs running OS X. I have a PowerMac Quad and I want to set it up as a server so that my entire workgroup can access files from it in order to run InDesign and InCopy. How do I do this? Thanks in advance!

  • Qosmio G20 - how to reinstall Windows XP without recovery DVD?

    I am trying to install windows XP on the laptop. I bought the Qosmio without the reinstall cd . There is no Operating system installed on the hard drives at all. Everything is OK, till it asks for the raid drivers, then it says put the disc in 'A' dr

  • I have made a Flash gallery that works in DW but not in browsers

    Hi, I am fairly new to Flash and Dreamweaver and have encountered a problem with my CS4 Dreamwever and Flash. I have made two galleries in flash of 30-40 stills that change after 2 seconds in time line. I saved these and exported to DW as .swf files.

  • Tax Codes not visible

    Hi all, I have just migrated SAP B1 from 2005B to 2007. i am having a problem with the tax codes. all the tax codes seems to have migrated. I can see then when I write a query for all the tax codes. but i can only see the 5 basic codes when trying to

  • IE 10, EMET 4.0, Win7 SP1 kernelbase.dll error

    I am really not sure what on my Win 7 SP1 system is causing this issue, but with EMET 3.0 everything runs fine, when I upgrade it to EMET 4.0 it initiallly does not show anything "Running EMET" even though it has settings from a large number of progr