How to schedule report filtered by dynamic date based on the date the Agent runs

Hello
I have a question about delivering report using OBIEE agent.
If i am running an agent today to deliver report A, can I get report A based on Last Monday's date or any dynamic dates?
For example, say today is Dec 18th 2013 and my agent is running according to how I set the schedule. Now the deliver content will have report A being delivered. Now report A has a date column, normally this column is filtered by current date. But if it's delivered through agents to various users, Report A's data should be the previous Monday, so in this case Dec 9th 2013. When this agent is run again said on Dec 27th 2013, then report A should be filtered by Dec 16th 2013, which is the previous monday of Dec 27th.
Can something like this be achieved in OBIEE 11G?
Thanks in advance.

Yala,
Not a straight forward way
1) Let the report run through Agent with Current Date filter
2) once it ran for the first time you can see IBOT name/last run time(LAST_RUNTIME_TS) in  S_NQ_JOB
Create a repository variable 'last_run_agent' using below sql to get max(LAST_RUNTIME_TS)
select max(LAST_RUNTIME_TS) from s_nq_job where name = 'AGENT_NAME';
Edit the analysis report with current date filter and modify the filter condition accordingly to filter on newly created repository variable
Thanks,
Saichand

Similar Messages

  • How to schedule reports to be run and sent from Ad-hoc query.

    Dear Abapers,
    I got a requirement in which the user wants to know how to schedule reports to be run and sent from Ad-hoc query.
    Regards
    Venkat

    Ask him to look more carefully at the menu : Quickview > Execute > Exec. in background, then click on schedule
    Regards,
    Raymond

  • How to insert PO details in an ADF based form and initiate the process flow

    Hi All,
    Could any one let me know how to insert PO details in an ADF based form and initiate the process flow in oracle BPM. This ADF form will be custom one....How to create a ADF custom based form.Please let me know the step by step process..Am new to BPM
    Thanks in advance,
    sreevani

    Hi All,
    Could any one let me know how to insert PO details in an ADF based form and initiate the process flow in oracle BPM. This ADF form will be custom one....How to create a ADF custom based form.Please let me know the step by step process..Am new to BPM
    Thanks in advance,
    sreevani

  • FM to get previous sunday date based on current date(SY-DATUM)

    hi all,
    Is there any function module to get the previous sunday date based on current date(sy-datum)?
    Regards,
    Kapil Sharma

    Hi Kapil,
    You can follow the logic below:
    data:
    l_date like sy-datum, **TODAY
    l_date2 like sy-datum, **Previous Sunday
    data:
    l_daynr like HRVSCHED-DAYNR.
    *Get today's date
    l_date = sy-datum.
    *Gey today's day (Monday, Tuesday, etc.)
    CALL FUNCTION 'HRIQ_GET_DATE_DAYNAME'
    EXPORTING
    langu = 'EN'
    date = l_date
    IMPORTING
    daynr = l_daynr.
    CASE l_daynr.
    *If it is Monday
    WHEN 1.
    -Subtract 2 days for the previous Sunday
    CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
    EXPORTING
    id_date = l_date
    id-operator = '-'
    is_duration = 2
    IMPORTING
    ed_date = l_date2.
    *If it is Tuesday
    WHEN 2.
    CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
    EXPORTING
    id_date = l_date
    id-operator = '-'
    is_duration = 3
    IMPORTING
    ed_date = l_date2.
    *If it is Wednesday
    WHEN 3.
    CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
    EXPORTING
    id_date = l_date
    id-operator = '-'
    is_duration = 4
    IMPORTING
    ed_date = l_date2.
    *If it is Thursday
    WHEN 4.
    CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
    EXPORTING
    id_date = l_date
    id-operator = '-'
    is_duration = 5
    IMPORTING
    ed_date = l_date2.
    *If it is Friday
    WHEN 5.
    CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
    EXPORTING
    id_date = l_date
    id-operator = '-'
    is_duration = 6
    IMPORTING
    ed_date = l_date2.
    *If it is Saturday
    WHEN 6.
    CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
    EXPORTING
    id_date = l_date
    id-operator = '-'
    is_duration = 7
    IMPORTING
    ed_date = l_date2.
    *If it is Sunday
    WHEN 7.
    CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
    EXPORTING
    id_date = l_date
    id-operator = '-'
    is_duration = 8
    IMPORTING
    ed_date = l_date2.
    ENDCASE.
    Regards,
    Dilek

  • FM to get the previous sunday date based on current date(sy-datum)

    hi all,
    Is there any function module to get the previous sunday date based on current date(sy-datum)?
    Regards,
    Kapil Sharma
    Moderator Message: Basic date related questions are not allowed
    Edited by: Suhas Saha on Sep 19, 2011 11:39 AM

    Hi,
    There are function modules to find out the current day of the week depending on sy-datum. These are as below:
    1. DATE_COMPUTE_DAY - Returns a number indicating what day of the week the date falls on. e.g. Monday is returned as a 1, Tuesday as 2,...., Sunday as 7.
    2. RH_GET_DATE_DAYNAME  - Returns the day based on the date provided, e.g. Monday, Tuesday,..., Sunday.
    Using any of the above, if you can find out the current day, then you can calculate and compute the date of the previous Sunday.
    My observation is that using the first FM might make the calculation simpler.
    Hope this is of help to you.
    Regards,
    Shayeree

  • How to create a dynamic RTF report which creates dynamic columns based on dynamic column selection from a table?

    Hi All,
    Suppose I have table, whose structure changes frequently on daily basis.
    For eg. desc my_table gives you following column name on Day 1
    SQL > desc my_table;
    Output
    Name
    Age
    Phone
    On Day 2, two more columns are added, viz, Address and Salary.
    SQL > desc my_table;
    Output
    Name
    Age
    Phone
    Address
    Salary
    Now I want to create an Dynnamic RTF report which would fetch data from ALL columns from my_table on daily basis. For that I have defined a concurrent program with XML as output type and have attached a data template/data definition to it which takes in XML as input and gives final output of conc program in EXCEL layout. I am able to do this for constant number of columns, but dont know how to do it when the number of columns to be displayed changes dynamically.
    For Day 1 my XML file should be like this.
    <?xml version="1.0" encoding="UTF-8"?>
    <dataTemplate name="XYZ" description="iExpenses Report" Version="1.0">
    <dataQuery>
    <sqlStatement name="Q2">
    <![CDATA[
    SELECT Name
    ,Age
    ,Phone
    FROM my_table
    ]]>
    </sqlStatement>
    </dataQuery>
    <dataStructure>
    <group name="G_my_table" source="Q2">
      <element name="Name" value="Name" />
      <element name="Age" value="Age" />
      <element name="Phone" value="Phone" />
    </group>
    </dataStructure>
    </dataTemplate>
    And my Day 1, EXCEL output from RTF template should be like this.
    Name     Age     Phone
    Swapnill     23     12345
    For Day 2 my XML file should be like this. With 2 new columns selected in SELECT clause.
    <?xml version="1.0" encoding="UTF-8"?>
    <dataTemplate name="XYZ" description="iExpenses Report" Version="1.0">
    <dataQuery>
    <sqlStatement name="Q2">
    <![CDATA[
    SELECT Name
    ,Age
    ,Phone
    ,Address
    ,Salary
    FROM my_table
    ]]>
    </sqlStatement>
    </dataQuery>
    <dataStructure>
    <group name="G_my_table" source="Q2">
      <element name="Name" value="Name" />
      <element name="Age" value="Age" />
      <element name="Phone" value="Phone" />
      <element name="Address" value="Address" />
      <element name="Salary" value="Salary" />
    </group>
    </dataStructure>
    </dataTemplate>
    And my Day 2, EXCEL output from RTF template should be like this.
    Name     Age     Phone     Address     Salary
    Swapnill     23     12345         Madrid     100000
    Now, I dont know below things.
    Make the XML dynamic as in on Day 1 there must be 3 columns in the SELECT statement and on Day 2, 5 columns. I want to create one dynamic XML which should not be required to be changed if new columns are added in my_table. I dont know how to create this query and also create their corresponding elements below.
    Make the RTF template dyanamic as in Day1 there must 3 columns in EXCEL output and on Day 2, 5 columns. I want to create a Dynamic RTF template which would show all the columns selected in Dynamic XML.I dont know how the RTF will create new XML tags and how it will know where to place it in the report. Means, I can create RTF template on Day 1, by loading XML data for 3 columns and placing 3 XML tags in template. But how will it create and place tags for new columns on Day 2?
    Hope, you got my requirement, its a challenging one. Please let me know how I can implement the required solution using RTF dynamically without any manual intervention.
    Regards,
    Swapnil K.
    Message was edited by: SwapnilK

    Hi All,
    I am able to fulfil above requirement. Now I am stuck at below point. Need your help!
    Is there any way to UPDATE the XML file attached to a Data Definition (XML Publisher > Data Definition) using a standard package or procedure call or may be an API from backend? I am creating an XML dynamically and I want to attach it to its Data Definition programmatically using SQL.
    Please let me know if there is any oracle functionality to do this.
    If not, please let me know the standard directories on application/database server where the XML files attached to Data Definitions are stored.
    For eg, /$APPL_TOP/ar/1.0/sql or something.
    Regards,
    Swapnil K.

  • How to schedule reporting agent job?

    Hi,
    I have start a reporting agent pack after changing the
    variant. Now i have changed the variant.
    Then how to schedule the reporting agent pack?
    could any one help me out....
    Thanks
    Srinivas

    Hi,
    Check this.
    http://help.sap.com/saphelp_nw04/helpdata/en/45/67bd3cad649f5ce10000000a114084/content.htm
    Regards.

  • How to Schedule Report Output in EXCEL (.cvs) format for Planning 11.1.2.1

    Hi all,
    I'm using Planning 11.1.2.1 for entering data and generating reports manually via Workspace. I wanna set up an automation process with a batch scheduler.
    I've gone over the documentation. I've read about creating batches first then scheduling batches next.
    However, the biggest issue I have is that I want to extract all my reports into EXCEL Spreadsheet (.cvs) format and according to the docs, it only supports output in PDF or HTML for 11.1.2.1.
    Is this true? Is there a way to work around this by using Business Rules at command prompt?
    Thanks,
    N

    If you have the Financial Report open there are two options:
    - in the bottom right hand corner of the report click the link: "Export In Query ready Mode"
    (this opens the report so you can use it as an Excel retrieve)
    - from the Hyperion menu, select File>Export>Excel
    (this exports the headers as objects and the data grid, so you can manipulate in Excel).
    Cheers, Iain

  • How to Schedule Reports?

    Hi,
    Please clarify the doubts,
    In Content Management -> Reports -> Approval Maintenance Reports, how to schedule the reports and how to make it to run.
    And how to send these reports through mail for hourly basis automatically.
    Thanks in Advance
    Vani

    Dear Srinivasan,
    I translate your response:
    Not free:
    - you need the CR 2008 client license to create the reports and then the server license to distribute the reports
    - Visual Cut
    Free:
    Do you recommend (see Crystal Reports Viewers, Schedulers and Related Products)?:
    Crystal Delivery
    Logicity
    Thanks!

  • How to make Report to create dynamically from datamodel

    Hi All,
    I am able to make a report data, if the datamodel is create as sample data.
    I tried to map the datamodel which is doesn't contain any sample data and trying to map to report so that it can generate data dynamically. It always throws
    "Error: Data Model does not contain sample data. Please edit Data Model and save with sample data."
    I want to create a dynamic data so when ever I make a webservice call to runReport it must pick the data from datamodel and create the report.
    Thank's in advance.

    Sarada,
    1) After you create your data model then you next have to run it.
    Click on the XML icon on the right hand side:
    http://www.oracle.com/webfolder/technetwork/tutorials/obe/fmw/bi/bip/bip11g/gettingstarted/images/t30401.gif
    2) When you get to this page. Click on RUN
    http://www.oracle.com/webfolder/technetwork/tutorials/obe/fmw/bi/bip/bip11g/gettingstarted/images/t30310.gif
    3) Finally, and this is perhaps the step you are missing. Click on Save as Sample Data:
    http://www.oracle.com/webfolder/technetwork/tutorials/obe/fmw/bi/bip/bip11g/gettingstarted/images/t30402.gif
    Cheers
    Jorge
    p.s If this answers your question then please grant the points and close the thread

  • How to Schedule reports to SFTP  server?

    Hello friends,
    Can some one please give me an examples for scheduling reports to SFTP server using BOBJ SDK?
    Regards,
    Rakhy.

    Hi Rakhy,
    You cannot schedule a report to SFTP and also it is not supported by SAP.
    The same cannot be achieved thtrough CMC/BIlaunchpad and hence it is not possible to achive the same though sdks as there is no option available to schedule a report to SFTP.
    SAP BI 4.x does not provide any Build- In functionality to use the SFTP protocol with the Scheduler.
    Refer to the SAP Note below
    http://service.sap.com/sap/support/notes/1782625
    There is a workaround given at the link below is applicable to XI R2. You can probably implement that with your environment.
    http://scn.sap.com/docs/DOC-31576
    You can use BOBJ SDKs to Schedule a report to Unmanged Disk and then create a program object which will trigger its schedule as an file base event occurs  and send the report to SFTP.
    Thanks,
    Prithvi

  • Report to be generated,mailed based on Reminder date through background job

    Hi All,
    We have a requirement where in I need to mail the "Task Monitoring" report to the Personnel administrator based on the reminder date set for different task types mentioned in IT 0019.
    I am using T-code sm36 to set the background job on a monthly basis.
    I am able to mail the report for as per the reminder dates set in the "Task monitoring" report. But I want to know how the system will pick the reminder date on a monthly basis to mail the report accordingly.
    Eg. For the month of Jan, i have set the reminder dates falling in that very month in the selction output of "Task Monitoring" report and mailed.
    Now I want sytem to automatically pick the reminder dates and mail the report. Pls let me know the steps to make the sytem pick the next reminder dates on its own on monthly basis.
    Points would be rewarded for appropriate solutions.
    Thanks.
    Deepali

    Hi,
    After pressing save button to create a variant, system takes me to the Variant Attributes screen. There I select on "Selection variable" accross "Reminder date". I clcik on the "Dynamic date calculation".
    Then when i go to the "Name of Variable column" and i  select "First day of the month" from the drop down. Can u pls explain me how this would help me capture the "Reminder dates" on monthly basis falling on each month when i mail the report on monthly basis.
    Eg. For the month of Jan, i need all the reminder dates falling in this month.
    For the month of Feb, i need all the reminder dates falling in this month. Like this, It goes on all for all the months.
    Thanks.

  • A/R report u0096 Customer open items based on due date

    Hi all,
    Can anyone tell me if there is a standard report on AR side that gives me invoices due between certain dates, meaning I should be able to select due dates between 11/15/2006 and 11/30/2006 in the selection and the report should get me the customers with invoices that are due between the above dates for a company code.
    Thanks in advance
    Kumar

    Hi Kumar,
    there is no standard report which give you selection citeria to select range of due date. Since due date is calculated based on function module where it calculate Bline date+ terms of payment days.
    other std reports are:
    S_ALR_87012175 Open Items - Customer Due Date Forecast
    S_ALR_87012178 Customer Open Item Analysis by Balance of Overdue Items
    S_ALR_87012168 Due Date Analysis for Open Items
    Hope this helps.
    Please assign points as way to say thanks

  • Can you create a javascript dynamic menu based on security data in oracleDB

    I am looking for a dynamic javascript menu that is generated based on the user role... basically i get the user role from ldap and then I have a Security table in oracle data base that has the permission info and i want to generate my dynamic menu based on the data in the database table.... the table has the following columns
    private String userId;
    private String security_level; // page level , field level
    private String permission; //CRUD
    private String permissionType; //ALLOW, DENY

    Hello Suzie,
    It is possible but you have "many" ways to do it, since what will happen is the javascript will be generated by an application.
    Are you developing a J2EE application? with or without JSF?
    The best way will be to Google to find a good Javascript menu library, and adapt the generation of it based on the content of your database.
    Regards
    Tugdual Grall

  • How to get the data based on below data-----pls help me...

    Hi,
    i have the data in my table.......
    SET_ID SET_Name Status date user_name
    SET974     F698671     I     24/03/2011 10:40:05     TEST1
    SET974     F698671     I     24/03/2011 10:40:05     TEST1
    SET974     F698671     N     24/03/2011 10:40:05     TEST1
    SET974     F698671     I     24/03/2011 10:40:05     TEST1
    SET528     A258961     I     22/03/2011 9:40:05     TEST2
    SET528     A258961     N     22/03/2011 9:40:05     TEST2
    SET528     A258961     I     22/03/2011 9:40:05     TEST2
    SET528     A258961     I     22/03/2011 9:40:05     TEST2
    SET974     F698671     I     25/03/2011 13:40:05     TEST1
    SET974     F698671     N     25/03/2011 13:40:05     TEST1
    SET974     F698671     N     25/03/2011 13:40:05     TEST1
    SET974     F698671     I     25/03/2011 13:40:05     TEST1
    SET974     F698671     I     26/03/2011 15:40:05     TEST5
    SET974     F698671     N     26/03/2011 15:40:05     TEST5
    SET974     F698671     N     26/03/2011 15:40:05     TEST5
    SET974     F698671     I     26/03/2011 15:40:05     TEST5
    I want to know each user ,how many sets modified.
    based on above input data,my output would be in the following way:
    user_name no.of sets upated for single user
    TEST1 2
    TEST2 1
    TEST5 1

    Based on your sample data, why does TEST1 have a count of 2? From what I can see, the only SET_ID that is associated with TEST1 is SET974 so I would think that you'd want TEST1 to have a count of 1.
    If I ignore the data you posted and just look at the text of your requirements, I would guess that you wanted
    SELECT user_name, COUNT( DISTINCT set_id ) cnt
      FROM some_table
    GROUP BY user_nameThis won't give the output you said you wanted based on the sample data you provided, however, for the reason I outlined above.
    If you actually do expect to get the output you posted from the sample data you posted, can you explain in a bit more detail why TEST1 should have a value of 2? It would also be helpful to post the CREATE TABLE and INSERT statements rather than just dumping the data. If you provide DDL & DML, we can create the objects locally and verify our solutions rather than guessing based on eyeballing the data.
    Justin

Maybe you are looking for