Query to count ACTIVE records for each month

All,
I have a requirement to count the number of active customers for each month of an year. Let's say, we have 3 fields in the table:
ID               ActiveStart             ActiveEnd
1                 1/1/2014               11/30/2014
In this scenario, the member with ID was active for all the months (Jan-November) EXCEPT, December. So, the result set I am expecting for the Month of January to December is like below:
Month       CountOfMembers
Jan            1
Feb           1
Mar           1
April          1
May           1
June          1
July           1
August      1
Sept          1
Oct            1
Nov           1
Dec           0 (Since, the member was NOT active in this month)
Similarly, if you have another member whose start date is 1/1/2014 and termination is '5/31/2014', then, I would need to add 1 for months of January till May, the member WON'T be counted for the rest of the months. So, in this case, the count will be come
"2" for months January till May, it will remain "1" for June till November and still "O" for December.

>>I have a requirement to count the number of active customers for each month of an year. Let's say, we have 3 fields [sic: columns are not fields] in the table [sic: tables have names]: <<
Please follow basic Netiquette and post the DDL we need to answer this. Follow industry and ANSI-ISO standards in your data. You should follow ISO-11179 rules for naming data elements. You should follow ISO-8601 rules for displaying temporal data. We need to
know the data types, keys and constraints on the table. Avoid dialect in favor of ANSI-ISO Standard SQL. And you need to read and download the PDF for: 
https:--www.simple-talk.com-books-sql-books-119-sql-code-smells-
There is no magical universal “id” in RDBMS, tables have names and columns have constraints and types. Most of the work in SQL is done in the DDL. Here is a possible schema. 
CREATE TABLE Duty_Roster
(member_nbr INTEGER NOT NULL PRIMARY KEY,
 duty_start_date DATE NOT NULL,
 duty_end_date DATE NOT NULL,
CHECK (duty_start_date <= duty_end_date),
INSERT INTO Duty_Roster
VALUES 
(1, '2014-01-01', '2014-11-30'),
(2, '2014-01-01', '2014-05-31');              
>> In this scenario, the member with ID was active for all the months (Jan-November) EXCEPT, December. So, the result set I am expecting for the Month of January to December is like below: <<
A month is a temporal measurement that makes no sense without a year. But if you knew the ISO temporal model, you would see that you have what is called an INTERVAL data type. T-SQL does not support it yet. 
Since SQL is a database language, we prefer to do look ups and not calculations. They can be optimized while temporal math messes up optimization. A useful idiom is a report period calendar that everyone uses so there is no way to get disagreements in the DML.
The report period table gives a name to a range of dates that is common to the entire enterprise. 
CREATE TABLE Month_Periods
(month_name CHAR(10) NOT NULL PRIMARY KEY
   CHECK (month_name LIKE  '[12][0-9][0-9][0-9]-[01][0-9]-00'),
 month_start_date DATE NOT NULL,
 month_end_date DATE NOT NULL,
  CONSTRAINT date_ordering
    CHECK (month_start_date <= month_end_date),
etc);
These report periods can overlap or have gaps. I like the MySQL convention of using double zeroes for months and years, That is 'yyyy-mm-00' for a month within a year and 'yyyy-00-00' for the whole year. The advantages are that it will sort with the ISO-8601
data format required by Standard SQL and it is language independent. The pattern for validation is '[12][0-9][0-9][0-9]-00-00' and '[12][0-9][0-9][0-9]-[01][0-9]-00'
SELECT M.month_name, COUNT(R.member_nbr) AS member_cnt
  FROM Month_Periods AS M,
       Duty_Roster AS R
 WHERE M.month_start_date 
       BETWEEN R.duty_start_date AND R.duty_end_date
   AND M.month_end_date 
       BETWEEN R.duty_start_date AND R.duty_end_date;
We had no business rules about partial months, so I guessed. 
--CELKO-- Books in Celko Series for Morgan-Kaufmann Publishing: Analytics and OLAP in SQL / Data and Databases: Concepts in Practice Data / Measurements and Standards in SQL SQL for Smarties / SQL Programming Style / SQL Puzzles and Answers / Thinking
in Sets / Trees and Hierarchies in SQL

Similar Messages

  • How to get count of records for each type from internal table

    Hi Guys,
    I want to implement a logic to find out the count of records in a internal table.
    Assume my internal table have one field having the entries as shown below.
    Internal table Entries
    10
    10
    10
    11
    11
    12
    12
    12
    12
    13
    14
    14
    15
    15
    15
    15
    15
    16
    16
    17
    18
    19
    20
    20
    20
    ....... etc....
    I should get an output as below
    10's - 3
    11's -2 ,
    12's - 4.... etc..
    Could any one help me how to do this.
    Thanx,
    Kumar

    REPORT  zzz.
    DATA: i(100),
          t(100),
          j TYPE n.
    TYPES: BEGIN OF gt_int_type,
            linex(100) TYPE c,
           END OF gt_int_type.
    DATA: gt_int TYPE STANDARD TABLE OF gt_int_type,
          wa_int LIKE LINE OF gt_int.
    START-OF-SELECTION.
      wa_int-linex = '10'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '10'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '10'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '11'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '11'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '12'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '12'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '12'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '12'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '13'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '14'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '14'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '15'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '15'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '15'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '15'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '15'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '16'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '16'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '17'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '18'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '19'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '20'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '20'.
      APPEND wa_int TO gt_int.
      wa_int-linex = '20'.
      APPEND wa_int TO gt_int.
      LOOP AT gt_int INTO wa_int.
        WRITE:/ wa_int-linex.
      ENDLOOP.
      ULINE.
      SKIP 3.
      SORT gt_int BY linex.
      READ TABLE gt_int INDEX 1 INTO i.
      j = 0.
      LOOP AT gt_int INTO wa_int.
        IF wa_int-linex EQ i.
          j = j + 1.
        ELSE.
          WRITE:/ i,'''s = ', j.
          j = 1.
          i = wa_int-linex.
        ENDIF.
      ENDLOOP.
      WRITE:/ i,'''s = ', j.
    consider clearing leading/trainling spaces...

  • SQL help: return number of records for each day of last month.

    Hi: I have records in the database with a field in the table which contains the Unix epoch time for each record. Letz say the Table name is ED and the field utime contains the Unix epoch time.
    Is there a way to get a count of number of records for each day of the last one month? Essentially I want a query which returns a list of count (number of records for each day) with the utime field containing the Unix epoch time. If a particular day does not have any records I want the query to return 0 for that day. I have no clue where to start. Would I need another table which has the list of days?
    Thanks
    Ray

    Peter: thanks. That helps but not completely.
    When I run the query to include only records for July using a statement such as following
    ============
    SELECT /*+ FIRST_ROWS */ COUNT(ED.UTIMESTAMP), TO_CHAR((TO_DATE('01/01/1970','MM/DD/YYYY') + (ED.UTIMESTAMP/86400)), 'MM/DD') AS DATA
    FROM EVENT_DATA ED
    WHERE AGENT_ID = 160
    AND (TO_CHAR((TO_DATE('01/01/1970','MM/DD/YYYY')+(ED.UTIMESTAMP/86400)), 'MM/YYYY') = TO_CHAR(SYSDATE-15, 'MM/YYYY'))
    GROUP BY TO_CHAR((TO_DATE('01/01/1970','MM/DD/YYYY') + (ED.UTIMESTAMP/86400)), 'MM/DD')
    ORDER BY TO_CHAR((TO_DATE('01/01/1970','MM/DD/YYYY') + (ED.UTIMESTAMP/86400)), 'MM/DD');
    =============
    I get the following
    COUNT(ED.UTIMESTAMP) DATA
    1 07/20
    1 07/21
    1 07/24
    2 07/25
    2 07/27
    2 07/28
    2 07/29
    1 07/30
    2 07/31
    Some dates donot have any records and so no output. Is there a way to show the missing dates with a COUNT value = 0?
    Thanks
    Ray

  • I need a query that selects the amount of records for each day in a table.

    I need a query that selects the amount of records for each
    day in a table.
    Eg the result would be:
    date 1 14
    date 2 3
    etc
    Any ideas?

    sorted:
    SELECT count([commentID]),convert(varchar, dateAdded, 112)
    FROM COMMENTSgroup by convert(varchar, dateAdded,
    112)

  • How to apply Date condition for each month in 12 month period to my SQL query

    I am trying to retrieve all Outstanding Problem tickets in my Trendline SSRS report.
    I need to pull the OpenDate <= Last day of last month And CloseDate >= 1st day of current month
    for each month in the Last 12 months. How do I accomplish this in my query?
    I must also need to pull the oustanding tickets for the next 11 months in the same query
    where it will automatically pull the outstanding tickets for when a new month comes
    in out of the 12 month period?
    Here's a sample of my query to pull July 2013 Outstanding Problem tickets:
    Select OpenDate, CloseDate, Ref_Num, Type, status
    From Call_Req
    Where OpenDate <= '2013-07-31 00:00:00' And CloseDate >= '2013-08-01 00:00:00'
    And Type = 'P'
    My Results:
    OpenDate
    CloseDate
    Ref_Num
    Type
    status
    6/13/2013 7:41
    8/26/2013 12:41
    P1726456FY13
    P
    CL
    6/13/2013 8:17
    8/23/2013 12:31
    P1726612FY13
    P
    CL
    6/13/2013 10:17
    9/6/2013 16:54
    P1727352FY13
    P
    CL
    7/12/2013 10:46
    9/6/2013 10:23
    P1812568FY13
    P
    CL
    7/18/2013 10:17
    9/6/2013 8:53
    P1830452FY13
    P
    CL
    7/29/2013 15:54
    9/6/2013 16:16
    P1862906FY13
    P
    CL
    5/17/2013 20:51
    8/22/2013 9:09
    P1653380FY13
    P
    CL
    5/30/2013 13:29
    8/26/2013 7:33
    P1685693FY13
    P
    CL
    7/15/2013 14:14
    9/7/2013 9:42
    P1818874FY13
    P
    CL
    6/7/2013 15:49
    9/6/2013 16:46
    P1712265FY13
    P
    CL
    7/18/2013 10:25
    9/7/2013 9:18
    P1830516FY13
    P
    CL
    7/24/2013 16:30
    8/12/2013 18:26
    P1849909FY13
    P
    CL
    Talitha Davis

    Would this Work?
    DECLARE @now DATE = GETDATE();
    WITH months(lvl, daydate)
    AS (
    SELECT
    1,
    @now
    UNION ALL
    SELECT
    lvl + 1,
    DATEADD(MONTH, -1, daydate)
    FROM months
    WHERE lvl < 12
    ), dateranges(period, opendate, closedate)
    AS (
    SELECT
    CAST(YEAR(daydate) AS CHAR(4))
    + '-'
    + RIGHT('0' + CAST(MONTH(daydate) AS varCHAR(2)), 2),
    DATEADD(DAY, 0-DAY(daydate), daydate),
    DATEADD(DAY, 1-DAY(daydate), daydate)
    FROM months
    SELECT
    b.period,
    a.OpenDate,
    a.CloseDate,
    a.Ref_Num,
    a.Type,
    a.status
    From Call_Req a
    INNER JOIN dateranges b
    ON
    a.OpenDate <= b.opendate
    AND
    a.CloseDate >= b.closedate
    WHERE Type = 'P';
    Microsoft Certified Trainer & MVP on SQL Server
    Please "Propose as Answer" if you got an answer on your question, and vote for it as helpful to help other user's find a solution on a similar question quicker.

  • MDX to dynamically create period to date for each month of current year

    I need some help with MDX. I am not even sure if this is possible to do but here is what I need.  Any help is greatly appreciated.
    I have a Date dimension with a hierarchy defined as Year-Qtr-Month-Date
    I have a measure called Rentals
    Assume the current date is 10/24/2014.  I want to display by month for the year 2014, the sum of rentals equivalent to the current MTD.  So January would sum 1/1 thru 1/24.  February would sum 2/1 thru 2/24.  March would sum 3/1 thru
    3/24, etc.
    On the end of the current month, all months would display the sum of the whole month. I am not concerned if a month ends on the 30th or 31st.  The end is end.
    It needs to be dynamic enough so that if the current date is the 27th, each month would sum from the 1st to the 27th.

    Hi Rocko,
    According to your description, you want to compare the sum amount of rentals for each month, right?
    In MDX, we can use
    PARALLELPERIOD function returns a member from a prior period in the same relative position as a specified member. So you can use the query like
    with set Period as {[Arrival Date].[Date].[Month].&[2014]&[1]:[Arrival Date].[Date].[Month].&[2014]&[27]}
    member [Arrival Date].[Date].[0] as sum({Period})
    member [Total Amount N-1] as (PARALLELPERIOD([Arrival Date].[Date].[Month], 1, [Arrival Date].[Date].[Year].&[11]), [Measures].[Total Amount])
    Here is a sample query on AdventureWorks cube.
    SELECT ParallelPeriod ([Date].[Calendar].[Calendar Semester]
    , 3
    , [Date].[Calendar].[Month].[October 2003])
    ON 0
    FROM [Adventure Works]
    Regads,
    Charlie Liao
    TechNet Community Support

  • Select one record for each member of the group

    Hi,
    am having a table where in i will be having data for so many group members. i need to fetch data for a particular group members whose number of rows of data may be more in numbers (but i want only one row of data for each member of the group)
    here is the query for fetching all rows of data
    select RI.RESOURCE_NAME,TR.MSISDN,TR.ADDRESS1_GOOGLE, TR.MSG_DATE_INFO, FROM TRACKING_REPORT TR, RESOURCE_INFO RI
    WHERE TR.MSISDN IN (SELECT MSISDN FROM RESOURCE_INFO WHERE GROUP_ID ='1' AND COM_ID=2 ) AND RI.MSISDN=TR.MSISDN
    order by MSG_DATE_INFOoutput of this query is...
    >
    ddd     12345          13-Mar-10 19:43:03
    eee     54321     Tamil Nadu, India      13-Mar-10 19:39:48
    ddd     12345          13-Mar-10 19:32:58
    eee     54321     Tamil Nadu, India      13-Mar-10 19:30:07
    ddd     12345          13-Mar-10 19:23:08
    eee     54321     Tamil Nadu, India      13-Mar-10 19:20:14
    fff     98765          13-Mar-10 19:19:22
    ddd     12345          13-Mar-10 19:13:01
    eee     54321     Tamil Nadu, India      13-Mar-10 19:09:50
    ddd     12345          13-Mar-10 19:02:56
    eee     54321     tn,ind      13-Mar-10 18:59:49
    ddd     12345          13-Mar-10 18:53:08
    eee     54321     tn,ind      13-Mar-10 18:49:50
    ddd     12345          13-Mar-10 18:42:56
    eee     54321     tn,ind      13-Mar-10 18:39:50
    ddd     12345          13-Mar-10 18:33:00
    eee     54321     tn,ind      13-Mar-10 18:29:50
    ddd     12345          13-Mar-10 18:22:54
    eee     54321     tn,ind      13-Mar-10 18:19:50
    ddd     12345          13-Mar-10 18:12:56
    eee     54321     tn,ind      13-Mar-10 18:09:50
    ddd     12345          13-Mar-10 18:02:54
    eee     54321     tn,ind      13-Mar-10 18:00:02
    fff     98765     Tamil Nadu, India      13-Mar-10 17:59:26
    fff     98765     Tamil Nadu, India      13-Mar-10 17:54:26
    ddd     12345          13-Mar-10 17:52:56
    eee     54321     tn,ind      13-Mar-10 17:49:50
    fff     98765     Tamil Nadu, India      13-Mar-10 17:49:25
    fff     98765     Tamil Nadu, India      13-Mar-10 17:44:26
    ddd     12345          13-Mar-10 17:42:56
    >
    from this output i want only one latest record for each member(ddd,eee,fff). i.e
    >
    ddd     12345          13-Mar-10 19:43:03
    eee     54321     Tamil Nadu, India      13-Mar-10 19:39:48
    fff     98765          13-Mar-10 19:19:22
    >
    how to modify the query to achieve this...?

    Hi,
    This is not giving the result which i want...
    table is
    CREATE TABLE TRACKING_REPORT
      ID               NUMBER,
      MSISDN           NUMBER(12)                   NOT NULL,
      X                NUMBER(15,8)                 NOT NULL,
      Y                NUMBER(15,8)                 NOT NULL,
      TIME_STAMP       DATE,
      MSG_DATE_INFO    DATE                         DEFAULT sysdate,
      ADDRESS1_GOOGLE  VARCHAR2(400 BYTE),
      ADDRESS2_GOOGLE  VARCHAR2(400 BYTE),
      ADDRESS_MLINFO   VARCHAR2(400 BYTE),
      REQ_ID           VARCHAR2(30 BYTE)
    CREATE TABLE RESOURCE_INFO
      RESOURCE_ID    NUMBER,
      MSISDN         NUMBER,
      RESOURCE_NAME  VARCHAR2(25 BYTE),
      ADDRESS        VARCHAR2(100 BYTE),
      COM_ID         VARCHAR2(20 BYTE),
      ADMIN_ID       NUMBER,
      TIME_STAMP     DATE                           DEFAULT SYSDATE,
      GROUP_ID       NUMBER
    )

  • Min date for each month from list

    Hi all,
    I need to select only minimal date for each month from this sample query:
    select date '2011-01-04' as adate from dual union all
    select date '2011-01-05' as adate from dual union all
    select date '2011-01-06' as adate from dual union all
    select date '2011-02-01' as adate from dual union all
    select date '2011-02-02' as adate from dual union all
    select date '2011-02-03' as adate from dual union all
    select date '2011-10-03' as adate from dual union all
    select date '2011-10-04' as adate from dual union all
    select date '2011-10-05' as adate from dual So the result should be:
    04.01.2011
    01.02.2011
    03.10.2011How do I perform it?

    WITH dates
         AS (SELECT DATE '2011-01-04' AS adate FROM DUAL
             UNION ALL
             SELECT DATE '2011-01-05' AS adate FROM DUAL
             UNION ALL
             SELECT DATE '2011-01-06' AS adate FROM DUAL
             UNION ALL
             SELECT DATE '2011-02-01' AS adate FROM DUAL
             UNION ALL
             SELECT DATE '2011-02-02' AS adate FROM DUAL
             UNION ALL
             SELECT DATE '2011-02-03' AS adate FROM DUAL
             UNION ALL
             SELECT DATE '2011-10-03' AS adate FROM DUAL
             UNION ALL
             SELECT DATE '2011-10-04' AS adate FROM DUAL
             UNION ALL
             SELECT DATE '2011-10-05' AS adate FROM DUAL)
    SELECT TO_CHAR (MIN (adate), 'DD.MM.YYYY') adate
      FROM dates
      GROUP BY to_char(adate, 'YYYY.MM')
    ADATE
    03.10.2011
    01.02.2011
    04.01.2011

  • Loading the cube from 3 datasources and getting 3 records for each keyfield

    Hi All,
    I am loading an InfoCube from 3 separated datasources. These 3 datasources are UD Datasources and their unique source system is UD Connect.
    Each of the datasource contains a unique key field 'Incident Number' (same as we use have in Datasources for DSO).
    The problem is, when I am loading data with these 3 datasources to the cube, for each 'Incident number' there becomes 3 records.
    We have reports on this Infocube and the report also displays 3 records for each incident number.
    If I remove Incident Number key field from 2 of the Datasources, the data from these datasources do not reach to the Cube.
    For many of you, this may be a minor problem ( or may not be a problem at all !!! ) , but as a New Joinee in SAP field, this has become a showstopper issue for me.
    Please suggest.
    Thanks in Advance.

    Hi Pravender,
    Thanks for your interest.
    The scenario is, I have 3 datasources form the same source system, All the 3 datasources have different fields except 'Incident Number'. So, each and every field has only one value in the report. But due to 3 separate datasources, it creates 3 records displahying values of each datasource in a separate record.
    There is no field in the query output which is having different values for the different source systems. Due to 3 records in the cube, one record will contain the value for a particular field and the other two records will show a Blank for that field.
    Regards.

  • Calculate total empoyee days (as of present) that have elapsed for each month in a FY

    Hello, everyone,
    I'm running CF server connecting to an Oracle (11g)  db.
    I have a table that keeps track of projects (past, present, future) and need a way to sum the days for each project, for each month, that have happened.
    For example.
    ID   -
    Name         
    -   Start
    -   Stop 
    - Employees
    001
    Project A     
    01-Oct-14
    31-Dec-14      
    8
    002
    Project B     
    06-Feb-15
    21-Feb-15      
    9
    003
    Project C     
    30-Oct-14
    29-Nov-14      
    3
    004
    Project D     
    26-Dec-14
    16-Apr-15     
    21
    I'm trying to create an overview where the display will have the months of a Fiscal Year go across the page, indicating the number of employee days for each project that have elapsed. (NOT counting the current day).  New requirement: To make matters even more complex, there is a related table for the employees showing what dates they actually started and stopped (not every employee starts on day 1 and ends on the last day.. some start a day or two after the project start, etc.)
    I'm not wrapping my head around this, for some reason. Mental block. Any ideas?
    Someone in another forum suggested a PIVOT.  That's above my paygrade (I have never used PIVOT, don't understand how it works, etc.)
    V/r,
    ^_^

    This may be a good start. Display by Month Year the Average and Sum Dates between Start and Stop by Project.
    SELECT      CAST    (
            (CAST(MONTH(Start) AS varchar(2)) + '/01/' + CAST(YEAR(Start) AS varchar(4)))
            AS DateTime
        AS DatePeriod,
        AVG(DateDiff(day, Start, Stop)) AS AverageDaysToClose,
        SUM(DateDiff(day, Start, Stop)) AS SumTotalDaysToClose,
        Name
    FROM     Projects
    GROUP BY CAST    (
            (CAST(MONTH(Start) AS varchar(2)) + '/01/' + CAST(YEAR(Start) AS varchar(4)))
            AS DateTime
        Name
    ORDER BY DatePeriod, Name

  • Urgent !!Report Fiscal year for each Month i.e.12mnths

    Hi All,
      I have a cube with following details.
    1.Revenue Value ==1200
    2.Fiscal year==2007
    3.Product type==A
    But If i need to create a Dashboard Report with this Cube,
    But it has display tht Fiscal Year Value 2000 for each month
    Like ..KF=1200/12(months)
    So i need display as follows for the graph...
    MONTH        JAN     FEB   MAR...............................DEC
    REVENUE     100    100    100...................................100
    THIS IS HOW MY REPORT SHLD BE EXECUTED..
    But I dont have any date or month field in my cube,how can I get it for Each month as above..??????
    Can any one explain me & suggest me how to proceed..???
    Thnx
    BI Learner

    Hi Voodi,
    That is the only solution... which i have in my mind...Let me try it out & get back to u..
    But as well I have another KF under that Revenue which display for each month & we need to run a dashboard with line diagram where one line for Revenue & another for PO which shld give a comparison for all the months...
    Does this work out??
    Thanks a lot for ur ideas.

  • How can i see cost centre wise employee level salary breakdown for each month ? can anybody help me.

    plz anyone help me.

    thanks, Nguyen. can i get a employee salary breakdown for each month with this tcode.

  • Within the budget template; how would one create an entire year worth of a budget; with out having to create a separate page for each month?

    Help!
    Loving the budget template, but I would like to be able to create an entire years worth of a buget with out creating a whole new transaction/budget page for each month. How do I get the new transaction to identify a new budget chart?
    Thanks, Emily

    Emily,
    No need to think the budget template is only for one month.  Just keep typing the date in the date column of the "Transactions" sheet and the details will update.  You should adjust the budget categories to match the duration of time you want to use.
    If you do want month-by-month, then you can switch to the "Transactions" sheet, select the table, cut
    then switch back to the "Budget" sheet, paste.
    Now rename the "Budget" sheet something like "Budget Jan 2014", and delete the "Transactions" sheet. Set the budget for Jan in the column I highlighted above.  The subsequent months, duplicate the monthly budget:
    Then adjust the the entries in the transactions table inside this sheet.

  • When we drilldown at document level it displays one record for each cube

    Dear Experts .
    The users want to see the report by status for the order detail report at document level it displays one record for each cube .
    They want to see the single line for the order quantity , Amount, Billing quantity delivery and amount along with the Sales order number , billing document number billing date , delvert date ..et in signgle line. ( Sale order DeliveryBilling)
    When we are doing on Multiprovider recording displaying from each cube.
    We have tried with Constant selections and it is not giving the required results m since these want to see by status. Due to huge data performance reasons we re unable to use it .
    Please provide your valuable inputs.
    Thanks,
    Mahesh.

    Mahesh,
    If you want to get detail data with respect to Sales order - delivery - Billing, on top of Multiprovider you can come up with Constant selection.
    But I am not clear that why constant selection is not working properly, can I have some light on that.
    Probably, you are struggling with multiple records .
    I suggest you to go with end routine and map all fields to one IC and do reporting on that single IC, then your requirement will fulfill.
    But here we need to take care of performance issues and process chain scheduling wile loading deltas.
    If Multiprovider is not working properly , then try with Infoset(If you have more than 2 ICs it not possible).
    Regards,
    rvc

  • Year Duplicated For Each Month

    Hey everyone,
    I am using Oracle Business Intelligence 11.1.1.6.2 currently and I have just tried to create a report, but there is a problem.
    I drag & drop the year column from the Subject Area section to the right. Instead of getting:
    2005
    2006
    2007
    I get 2005 twelve times, 2006, another twelve times, etc. as if the second column shows the months. The only column I have selected from the subject area is the year column, however. There is nothing else.
    Any ideas on what may be causing this? Trying different browsers didn't work.
    Best Regards,
    Cihan

    Before I try your suggestions, I have found some sort of workaround for this:
    I go to Column Properties, then select Column Format. Value Suppression -> Suppress
    With this selected, each year appears just once, not twelve times (once for each month).
    My Fact table is joined to the Dimension table with this statement:
    "YK_DISCREPANCY".""."DW"."DIM_MONTH"."MONTH" = "YK_DISCREPANCY".""."DW"."FACT_DISCREPANCY_DETAIL"."MONTH_DISCREPANCY" AND "YK_DISCREPANCY".""."DW"."DIM_MONTH"."YEAR" = "YK_DISCREPANCY".""."DW"."FACT_DISCREPANCY_DETAIL"."YEAR_DISCREPANCY"
    This is most likely the reason, right?
    BR

Maybe you are looking for