In report in one colum month data in another colum YTD toal required

Dear All,
              Please can anybody help me,it is important for me
                There is a requirement as below
when the user enters the value in varible screnn for some month (like april09) the the report will be in one column january09to april month total value and in another column only april month value has to come.value of the purchase documents.
please can anyody help me out from this issue.
Thanks & Regards
Sathish

Hi,
You can use this code.
I have written the code assuming that your YTD includes the month of the date that user enters.
CASE I_VNAM.
WHEN 'YCUR_MONTHS_YTD'.
IF I_STEP = 2. "after the popup
CLEAR L_S_RANGE.
LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE
WHERE VNAM = 'YCALDAY'.
CURDAY = LOC_VAR_RANGE-LOW(8).
concatenate curday(4) '01' into start_month.
end_month = curday(6).
CLEAR L_S_RANGE.
L_S_RANGE-SIGN = 'I'.
L_S_RANGE-OPT = 'BT'.
L_S_RANGE-LOW = start_month.
L_S_RANGE-HIGH = end_month.
APPEND L_S_RANGE TO E_T_RANGE.
ENDLOOP.
ENDIF.
WHEN 'YCUR_MONTH'.
IF I_STEP = 2. "after the popup
CLEAR L_S_RANGE.
LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE
WHERE VNAM = 'YCALDAY'.
IF SY-SUBRC = 0.
CURDAY = LOC_VAR_RANGE-LOW(8).
current_month = curday(6).
ENDIF.
ENDLOOP.
            L_S_RANGE-LOW  = current_MOnth.
            L_S_RANGE-SIGN = 'I'.
            L_S_RANGE-OPT  = 'EQ'.
            APPEND L_S_RANGE TO E_T_RANGE.
ENDIF.
ENDCASE
Regards,
Raghu

Similar Messages

  • Copy reports from one business objects server to another

    How do I copy all the reports published in my production BO server to my test server. I did this once but can not remember. Is it the import wizzard?

    yes you can use the import wizard to export your reports from one server to another server
    just open the import wizard, connect to your source server, choose object types you want to export (folders, reports, users,,,,etc),,, then choose the objects itself, then connect to the destination server, and the import wizard will guide you through this process.
    good luck

  • XML Data source - Referring from one section of data to Another section

    In my application, XML raw data is used as an input to the Crystal Report 2008. From this XML data, different type of report outputs are generated. So XML data has formatting information too. This formatting information need to be used in generating report.
    For Example, consider the below XML.
    <COFC>
         <REPORT_FORMAT>
              <REPORTS>
                   <REPORT>
                        <REPORT_ID>1</REPORT_ID>
                        <MEASUREMENT>
                             <MEAS_CODE>BOW_EPI</MEAS_CODE>
                             <DISPLAY_NAME>BOW</DISPLAY_NAME>
                        </MEASUREMENT>
                        <MEASUREMENT>
                             <MEAS_CODE>TTV_EPI</MEAS_CODE>
                             <DISPLAY_NAME>TTV</DISPLAY_NAME>
                        </MEASUREMENT>
                   </REPORT>
                   <REPORT>
                        <REPORT_ID>2</REPORT_ID>
                        <MEASUREMENT>
                             <MEAS_CODE>BOW_EPI</MEAS_CODE>
                             <DISPLAY_NAME>BOW-EPI</DISPLAY_NAME>
                        </MEASUREMENT>
                        <MEASUREMENT>
                             <MEAS_CODE>TTV_EPI</MEAS_CODE>
                             <DISPLAY_NAME>TTV_EPI</DISPLAY_NAME>
                        </MEASUREMENT>
                   </REPORT>
              </REPORTS>
         </REPORT_FORMAT>
         <REPORT_DATA>
              <MEAS_CODES>
                   <MEAS_CODE>BOW_EPI</MEAS_CODE>
                   <MEAS_CODE>TTV_EPI</MEAS_CODE>
              </MEAS_CODES>
         <REPORT_DATA>
    </COFC>
    In the above example, REPORT_FORMAT record has formatting information. REPORT_DATA record has actual report data.
    If report cooresponding to report_id 1 uses the above XML, then the output should be
    BOW
    TTV
    If report corresponding to report_id 2 uses the above XML, then the output should be
    BOW_EPI
    TTV_EPI
    In order to reduce the redundancy of the data, we decided to pass the formatting information with the data and use it in the report accordingly.
    But I couldn't achieve the result. I am thinking about having a function which takes MEAS_CODE as an input and returns the correct DISPLAY_NAME. To perform this iteration of REPORT_FORMAT record is necessary. I don't know how to do it. Please give me some guidlines to achieve this.
    If there is better way to do it, Please let me know. I have no other options, I need to use the report formatting information in my report.

    Please re-post if this is still an issue to the .NET Development - Crystal Reports Forum or purchase a case and have a dedicated support engineer work with you directly

  • Crystal report runs one way in designer and another in Infoview

    Post Author: jasonp
    CA Forum: Crystal Reports
    I have a Crystal report with a number formula that runs correctly in the designer, but comes up with incorrect values on the server. The formula is used to determine a range in the select expert, so I end up with completely different data. I'm not using any custom functions, just what Crystal gives you. We recently migrated the Infoview server and I suspect this is what is causing this since it worked before. The formula:
    CDbl (Mid ("1" + Mid (CStr (Year (date(dateadd("d",-(day(currentdate)),currentdate)))),3 ,2) + CStr ((date(dateadd("d",-(day(currentdate)),currentdate)) - CDate (Year (date(dateadd("d",-(day(currentdate)),currentdate))),01 ,01))+1),1 ,6))
    returns 107273 in the designer (correct), but returns 100273 in Infoview (incorrect).
    Any suggestions?

    Post Author: SKodidine
    CA Forum: Crystal Reports
    CSTR is not functioning as you expected because you are not accounting for the decimals and commas.  Here is what is happening. Results are step by step and color coded assuming you run this on 10/01/2007.
    The first half of the formula is the problem.
    Mid ("1" + Mid (cstr (Year (date(dateadd("d",-(day(currentdate)),currentdate)))),3 ,2)
                                                                                    09/30/2007
                                                                                    09/30/2007
                                                                                    2007
                                                                                    2,007.00 This is causing the problem.
                                                                                    00
    The second half of your formula brings in 273, combine that with above gives you 100273.
    You could change the MID values from (3,2) to (4,2) but I suggest using the optional arguments, which will give you the following:
    Mid ("1" + Mid (cstr (Year (date(dateadd("d",-(day(currentdate)),currentdate))),0,"",""),3 ,2)
                                                                                    09/30/2007
                                                                                    09/30/2007
                                                                                    2007
                                                                                    2007
                                                                                    07
    Combined with the second half of your formula it will give you 107273. 
    I suggest, for the second CSTR be used with the optional arguments for decimal places, thousands separator and decimal character, for uniformity.  The CDBL makes it numeric and puts the commas and decimals.
    Your final formula:
    CDbl (Mid ("1" + Mid (cstr(Year (date(dateadd("d",-(day(currentdate)),currentdate))),0, "",""),3 ,2) + cstr ((date(dateadd("d",-(day(currentdate)),currentdate)) - CDate (Year (date(dateadd("d",-(day(currentdate)),currentdate))),01 ,01))+1,0, "",""),1 ,6));

  • How to convert date in one timezone to date in another timezone?

    Hi,
    I am building a web site which can be accessed by people across world in different timezones. I have a requirement to collect the data from the users in their respective timezones and convert it to the timezone in which the server is hosted before saving it. E.g. a user in "Kwajalein" timezone (GMT - 12) enters date as "10/23/2007 21:00", the time for the server which is hosted in indian timezone (GMT + 5.30) would be "10/24/2007 14:30". If I use the following program to convert the dates in these timezones it gives me wrong output.
    TimeZone tz = TimeZone.getTimeZone("Kwajalein");
    DateFormat df = new SimpleDateFormat("MM/dd/yyyy HH:mm");
    df.setTimeZone(tz);
    Date d = df.parse("10/23/2007 21:00");
    TimeZone tz1 = TimeZone.getTimeZone("Asia/Calcutta");
    df.setTimeZone(tz1);
    System.out.println("date in IST-->" + df.format(d));
    The output of this program is
    date in IST-->10/23/2007 14:30
    The formatter has changed the time component however it hasn't changed the date. It still appears as 23.
    Am I doing anything wrong here?
    Please pass your comments.
    Thanks,
    Shashi

    Please see the following link it may be helpfull to you
    1) http://forum.java.sun.com/thread.jspa?threadID=755558
    2) http://myhowto.org/java/36-all-about-locale-sensitive-time-processing-in-java/

  • Report on one table and insert to another?

    Ok, this is probably a stupid question, but it's boggling me.
    I have a "view" that I am searching to pull back results on. Then I need to take that ID_NUMBER and pass it to a form that will take those values and insert them into a regular "table" with two unique values [id] = autonumber, and [id_number] = unique id from the view.
    I can get the form to filter the correct results, but it won't allow me to do the DML to process the row (insert)
    any suggestions?

    DISSREGARD PLEASE ... I'VE FIGURED IT OUT.

  • How to show a report for 'Previous Month' Data

    Hi Gurus,
    I have a requirement, where i have to default my report to show previous month data.
    Scenario:
    My prompts by Default are set to CURRENT (current year,quarter,month). once the user logs in, the report should display data for month 'Nov' instead of 'Dec'.
    I tried using TIMESTAMPADD() in the formula , but it didn't work, though i don't see any error. Not sure if i 'm missing something.
    Is there a way to achieve this.I 'm using OBIEE 11.1.1.6.
    Any help is highly Appreciated ! Please.
    Thanks,
    Ramya

    From what you wrote I am assuming the user can manually save the report results to the Excel file.
    If your report uses ALV Grid it is possible to export the data to a spreadsheet (one of the functions available in the ALV tool bar).
    If you have used WRITE statements it is also possible to save the output as a spreadsheet (menu System -> List -> Save), but the latter will not produce as nice a spreadsheet if the data don't form a matrix. In other words, some work may be necessary in the spreadsheet afterwards before it has the format your user wants.

  • Rolling 12 month data

    I use the query below to give me summary data for three
    categories, for each supplier number, base on a month and year
    selection :
    <cfquery name="qryGet_NORS" datasource="datasource">
    select suplier_number,table2.supplier_name,
    sum(case when date_sent is NULL and send_flag is NULL then 1
    else 0 end) as cannot_send,
    sum(case when date_sent is not NULL then 1 else 0 end) as
    total_send,
    sum(case send_flag when 'No' then 1 else 0 end) as
    total_disapproved
    FROM
    table1 LEFT JOIN Master_Buyer_Table ON table1.buyer_number =
    Master_Buyer_Table.buyer_number
    LEFT JOIN table2 ON table1.suplier_number =
    table2.supplier_number
    where substring(convert(varchar,date_resolved,101), 1, 2) =
    '#form.selectmonth#'
    and substring(convert(varchar,date_resolved,101), 7, 4) =
    '#form.selectyear#'
    group by suplier_number,table2.supplier_name
    </cfquery>
    I then use this QoQ to give me the grand totals for each
    supplier number.
    <cfquery dbtype="query" name="qryGet_Nors_sum">
    select sum(cannot_send) as total_cannot_send,
    sum(total_send) as total_total_send,
    sum(total_disapproved) as total_total_disapproved
    from qryGet_NORS
    </cfquery>
    What I need to do now is to get and output data for 12
    months, starting with the input month and year. For example, if
    they enter March 2008, then the above query would give me the three
    totals for the period. But now, I need the totals for the next
    month, April 2008, then the totals for May 2008, etc, all the way
    to March 2009.
    How would I modify the query to get all this information
    ?

    First thing is I don't know why you do the following
    where substring(convert(varchar,date_resolved,101), 1, 2) =
    '#form.selectmonth#'
    and substring(convert(varchar,date_resolved,101), 7, 4) =
    '#form.selectyear#'
    Should be
    where Month(date_resolved) = #form.selectmonth#
    and Year(date_resolved) = #form.selectyear#
    Now for the modification
    <!---
    So we create a date for the first of the month selected and
    return everything that is greater
    --->
    where date_resolved > #createDate(form.selectYear,
    form.selectMonth, 1)#
    <!---
    To only return one year of data
    creatre another date that is one year and one month greater
    then return everything smaller
    --->
    and date_resolved < #createDate(form.selectYear+1,
    form.selectMonth+1, 1)#
    Ken

  • Current Months Data - Automatic

    How to run a YTD report which will automatically show the current months data with no variable prompt for the same...?
    Is there any such variable which will run a report only for current months data.

    I dont think there is a std variable for current period. rather you can use fiscalyear/period time char and use 0FPER to derive current fiscalyear/period

  • Can one Crystal Report could contian Current Month, YTD and ITD data?

    Hi,
    I am trying to build a crystal report and be able to show data in summarized format on single report containing data for the current month, year to date and Inception to date.
    The difficulty that I find is the date ranges. Current month date range is different from YTD and ITD date.
    what would be the best way to show such data on crystal report? is there a sample report available that can help me to produce such report?
    your help will be highly appreciated, thanks!
    regards,
    Mansoor

    Hey Joe,
    if you have CRXI, take a look at the sample reports
    Record Selection on Date Range has some good examples
    you can do this with multiple Groups
    create a formula
    in to currentdate
    ( this group will cover your inception date to currentdate)
    second group will be a date group also, select year as your print by option for this group.
    3rd group also by date,
    select month.
    add fields to your details section, select the field, right click and select summary location,
    (add to all groups)
    you can then supress footers and headers as needed.
    Hope this helps.

  • Need to show Previous months data in report

    Hi All,
    I have a crystal report 2011 which shows monthly Cash data. It has 3 other columns like Previous 3 months cash data, previous 6 months cash data, Previous 12 months cash data in report.
    My report also has two parameters- start date and end date. If I give Start date as 1/1/2012 and end date as 12/31/2013 (two years date range) then correct data comes in all columns and for 2013 year, correct data is coming for Previous 12 months column. But if I give only one month date range like start date as 1/1/2013 and end date as 01/31/2013, then it is not showing correct data for these 3 columns - Previous 3 months cash data, previous 6 months cash data, Previous 12 months cash data. Ideally as per requirement, it should calculate previous months data regardless of parameter values and put data in respective columns.
    Any help/suggestion? Any trick which can help me to show correct data in all columns no matter what date range or months I am taking in parameters.
    Is it mandatory to have previous 12 Months data in report to calculate column-Previous 12 months Cash data?
    Thanks,
    Remi

    Hi Remi,
    You can try like this:
    I have given a some suggestions i.e You just take one parameter only because u can imagine 3 columns previous data display correctly i.e From Date
    Month parameter is also a alternate option.
    For Ex: Column1: From Date - 90 Days/3 Months  - we get the three months previous data correctly etc.
    Finally, create a stored procedure that returns the required columns and does all the calculations on the database side.
    Follow abhilash suggestion as well.
    Useful threads: Crystal Report Parameter Issue
    Pull Last 6 months of data
    Month to date data for Previous month
    How to find current month, previous month Net Sales by means of formula?
    Thanks,
    DJ

  • IW69 report not fetching all transaction data of current month.

    Dear Guru Ji,
    While doing testing IW69 report, i noticed that it is not displaying current month data. It is only get the data uptil last date of past month data in DEV & QA client.
    I wonder why this is happening?
    I tried using Malfunction start date & notification reference date input. But still the same result.
    Please guide me, what is going wrong?

    Hi,
    The selection option 'notification date' is based on notification date (VIQMEL-QMDAT). Transaction IW69 is used to display notification items - when there is no item data in the notification nothing will be returned.
    -Paul

  • Date Control should highlight more than one range of dates in a month.

    Hi All,
    Date Control should highlight more than one range of dates in a month.We are creating a web interface for PR01 ( Travel Management Module ) , in a month a traveller can have more than 2 trips and we need to highlight all the travel date ranges in the Web DynPro date range control.
    Thanks & Regards
    Gaurav Jain

    Hi Thomas,
       I used DateNavigatorLegend and DateNavigatorMarking and did not give any default value or context mapping to the DateNavigator element.
      The DateNavigator is now highlighting only the first dates of the ranges that I have created in the WDDOINIT method.The DateNavigatorMarking takes only one date not 2 dates in the properties So kindly suggest how to display multiple date ranges.
    Thanks & Regards
    Gaurav Jain

  • Previous month data in WebI Report

    Hi All,
    I have a universe created on a Bex Query. I don't have any variables created in the Bex Query. I have to create a WebI report with Calendar Year/Month as selection and depending on what user enters, i have to display Cost for the month entered by the user and cost for (month -1 ). For eg. if the user enters Feb 2009, then the report should display Cost for Jan 2009 and Feb 2009. I have created a filter for Calendar Year/Month. How do i bring previous month data in the report ? I don't have to modify the Bex Query. I have to achieve it on the BO side. Can you guys help on this problem.
    Thanks,
    Saachi

    Hi,
    There is a restriction in BO when you use it with SAP.
    When the user filters the data for FEB 2009, you will not be able to get data for JAN 2009 as it does
    not go again to the Bex query to fetch this data.
    The only workaround as of now to this is to bring all the data using Bex query by having a filter
    at the BO Query level where you say Cal year/month key = (From prompt) or 
                                                          Cal year/month key <> #.
    This is because it considers Cal year/month as string and so even at the universe level we will not
    be able to create a previous month formula.
    I hope this helps.
    Thanks,
    Kartik

  • What is an ageing report? What are the data sources used to develop an agin

    Hello BW gurus,
    I was going thru some of the BW resumes. I could not understand some of the points mentioned below. Kindly go thru them and please explain each of it.
    Thank you.
    TR.
    •     Developed AR ageing report, created invoice layout and processed invoices.
    What is an ageing report? What are the data sources used to develop an aging report
    •     Worked on month-end and year end processes such as Balance Sheet Statements and Profit and Loss Accounts. 
    What data sources does one use to get Balance sheet and P&L accounts tables and fields.
    •     Involved in the end to end implementation of BW at Reliance Group as a team member.
    What are the tasks a BW consultant normally performs when he is involved in an end to end implementation project or
    a full life cycle project?
    •     Extensively worked on BW Statistics to optimize the performance of Info Cubes and to create Aggregates.
    What do you mean when you say worked on BW statistics to optimize the performance of Info Cubes.
    What are aggregates why do you need them?
    •     Prepared design documents from the Business Requirement documents and identified the
    relevant data targets for satisfying the customer requirements.
    What are the design documents does one prepare, please give an example. 
    Is cube a data target?

    What is an ageing report? What are the data sources used to develop an aging report
    Aging refers to values in different time period ranges. Example, the customer (credit) aging report can look like this.
    customer (credit)  for current period, 0 to 30 days, 30 to 90 days, 90 to 120 days. This is the way aging is classified.
    What data sources does one use to get Balance sheet and P&L accounts tables and fields.
    For P&L information, you may use 0FI_GL_6 datasource (or 0FI_GL_10 if you use ERP 5.0 version). This datasource reads the same information used in R/3 transaction f.01 (table glt0).
    What are the tasks a BW consultant normally performs when he is involved in an end to end implementation project or a full life cycle project?
    Requirement gathering, blueprint creation, development etc
    Refer to posts on Sap Methodology  and Sap lifecyle
    What do you mean when you say worked on BW statistics to optimize the performance of Info Cubes. What are aggregates why do you need them?
    Please check these links
    http://help.sap.com/saphelp_nw04/helpdata/en/8c/131e3b9f10b904e10000000a114084/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/f0/3c8c3bc6b84239e10000000a114084/plain.htm
    What are the design documents does one prepare, please give an example.
    Design document is basically a document to say  how the design is to be developed for a particular solution ex: FI it says what is the data fow and what are the data targets  to be used and how data shld be stored  for providing the client a solution they need.
    Is cube a data target?
    Yes cube is a data target.
    Hope this Helps
    Anand Raj

Maybe you are looking for

  • How do I move data from a DAQ into and out of loops and structures?

    I have a set of RTD probes set up to read data into LabView through a DAQ. This block of code is in a while loop that executes alongside of several other loops simultaneously. I need to use the data from the RTD probes in other loops and case structu

  • Cut, Copy and Paste menus??

    Is there anybody who could give me code for "cut, copy and paste " menuitems (+ functionality) or tell me where I can find it on the internet? Thanx debeumers

  • Reclaim old email addresse of an unused printer

    Hi, I did a firmware upgrade of my HP CP1025NW printer and I made a mistake during re-registration of the ePrint functionality: I created a new ePrint printer for my printer and deleted the old assignment of the same printer. Now, I am not able to as

  • Shuffling Playlists/Albums

    So I got my iPod Nano and I love it to death. Being my first Apple product ever owned it took me a while to get used to the whole interface of iTunes and how it worked with iPod, but after a whole evening of playing with it I think I got the hang of

  • How do I get apps on my iPod touch using iOS 4.2

    How do I download apps from app store using iOS 4.2