Date comparision issue in the report

Hi Buddies,
I explain the scenario,
I have an dunning letter statement report which basically run for the three remainders (1,2,3) to the customer.
If the remainder 3 runs , i want to display the pervious remainder dates of 1 and 2 in my report.
If the remainder 2 runs, i want to display the pervious remainder date of 1 in my report.
I have date column in the dunning letter history table as Dunning_Date.
How can we achive this in sql?. I am getting struck over here, please give your advice to do it.
Regards
Ram

I think your date format is in different format with the date format u stored in presentation variable so better check the date format of the case function u wrote it in you variable that will solve the problem.

Similar Messages

  • Passing values to subreport in SSRS throwing an error - Data Retrieval failed for the report, please check the log for more details.

    Hi,
    I have the subreport calling from the main report. The subreport is based on MDX query agianst the SSAS cube. some dimensions in cube has values 0 and 1.
    when I try to pass '0' to the sub report as the parameter value, it gives an error "Data Retrieval failed for the report, please check the log for more details".
    Actually I am using table for storing these parameter values. In the main report I am calling this table (dataset) and passing these values to subreport.
    so I have given like [0],[1] and this works fine. when I give only either [0] or [1] then it is throwing an error.
    Could you please advise on this.
    Appreciate all and any help.
    Thanks,
    Divya

    Hi Divya,
    Based on the current description, I understand that there is no issue if you pass two values from main report to subreport, while the issue occurs when passing one value to subreport.
    To narrow down the issue, I want to confirm whether the subreport can run if there is only [0] or [1] in the subreport. If so, it indicates the query statements exist error in the subreport. If it’s not the case, this shows the issue occurs during passing
    values from main report to subreport. To make further analysis, please post the details of query statements of the subreport to the forum.
    Regards,
    Heidi Duan
    Heidi Duan
    TechNet Community Support

  • Smartform Implementation issue for the report  RFKORD50

    Hi,
    I have a requirement to implement a smartform for FI Invoice. 
    This smartform should be configured in OB96 for the print program RFKORD50.
    Currently the SAP Script F140_DOCU_EXC_01 has been configured for Standard print program RFKORD50.
    This SAP Script should be replaced with Smartform. But the issue is the report  RFKORD50 is designed to
    call only a SAP Scrip. Is there any better way to trigger the Smartform other than modifying the standard program?
    Thanks,
    Sailaja.A

    Hi,
    One of the very tough task, when it comes to migrate a script into Smartforms .. With a satndard print program ..
    You have a option on samrtform screen , just to migrate a Sapscript into Smartform .. But it is just a migration of Layout.. means just creation of WINDOWS and pages.. All the elements and text node creation still you need to do ..
    But one of the major challenge is to Customize your print program..
    So i will suggest you to create a Z copy of RFKORD50.. as print prgm .. Then you can feal better
    Now keep all the data selection part as it is .. collect it in different structure, then call your samrtform..
    and before calling your smartform, prepare your layout ..
    Very Imp suggestion, try to work on small small task.

  • Issue in the Reporting feature of SAP BPC NW 7.0

    Hi everyone,
    I am facing an issue with respect to the Reporting feature in SAP BPC NW 7.0 version. I am supposed to generate a P&L report using the EVDRE function.
    Issue-
    In the report that I have generated, the system is retrieving only a subset of the broad-level P&L heads. e.g. while BPC is retrieving the EBITDA, EBIT and PAT figures, it is not retrieving the Depreciation, Interest and Tax figures in the report. All the members that are not getting displayed are members with ACCTYPE= 'EXP', while the ones getting displayed are members with ACCTYPE= 'INC'.
    Even though the 'EXP' figures are not getting displayed, the amounts are getting deducted correctly. (i.e. even though Interest amount is not getting displayed in the report, the PBT figure being displayed is correctly calculated as PBT= EBIT-Interest).
    Also, I am able to see the amount in Interest payments, if I drill to the base-member elements (G/Ls in my case)
    Would really appreciate if someone could shed some light on what might be the probable issue.
    Thanks in advance,
    Sameer Rane

    Hi Nilanjan/All,
    Thanks a lot for your reply. I suppose, I was not very clear about my problem. The issue is with regards to the value for the Account-dimension members with ACCTYPE = 'EXP' and not with the members per se.
    Setting the MemberSet Filter addresses the issue of getting particular Dimension members in the report. In my case, I am already seeing all the necessary members in my report (I have explicitly created a list of all the members I want to see in my report in the MemberSet parameter). However, I am not able to see any values for these members for any of the time periods (even though the values exist).
    Also, I don't get any values for some of the INC items as well (e.g. OperationsIncome) inspite of the fact that the base member G/Ls under this account hold values.
    Would appreciate any help towards resolving this issue.
    Thanks in advance,
    Sameer

  • Report date prompt issue on the Sharepoint

    Hi,
    I am trying to run SSRS report on the sharePoint, but I am getting below error message "
    The
    value provided for the report parameter 'startdate' is not valid for its type.
    --->
    Microsoft.ReportingServices.Diagnostics.Utilities.ReportParameterTypeMismatchException:
    The value provided for the report parameter 'startdate' is not valid for its
    type."
    Can you suggest what's the cause of this?
    Many Thanks.

    Hi Aruna,
    From the error message, the value of the parameter didn't match the type of the parameter. Please re-open the report and enter an available value for the datetime.
    There are some similar posts about this issue, please take a look at:
    https://social.technet.microsoft.com/Forums/en-US/5bbc510d-6826-4a53-ade6-df71e0a4ed05/the-value-provided-for-the-report-parameter-startdate-is-not-valid-for-its-type?forum=sqlreportingservices
    https://technet.microsoft.com/en-us/library/aa256400(v=sql.80).aspx
    http://stackoverflow.com/questions/1442743/passing-date-as-a-parameter-to-a-subreport-another-report-to-use-as-a-parameter
    If this issue still exists, I suggest you create a new thread on SSRS forum. The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and other partners who read the forums regularly can either share their
    knowledge or learn from your interaction with us. Thank you for your understanding.
    SSRS:
    https://social.technet.microsoft.com/Forums/en-US/home?forum=sqlreportingservices
    Thanks,
    Wendy
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • Date Format issue in my report.

    Hello Experts-
    I created a report with a date prompt, which we need to enter two dates, start date and end date.
    I followed the steps as they were in this link
    http://obiee101.blogspot.com/2009/03/obiee-between-dates-prompt.html
    I changed the condition in the prompt to Date'1900-1-1' instead of TIMESTAMP'1900-1-1- 00:00:00
    I.e.,
    CASE WHEN 1=0 THEN CALENDAR.D_DATE ELSE Date' 1900-01-01' END
    and
    CASE WHEN 1=0 THEN CALENDAR.D_DATE ELSE Date '2999-12-31' END
    I stored those two dates in two presentation variables start_date, end_date
    In my report, I imposed a filter on my table that, date coulmn in my table is between Date'@(start_date}' and Date'@{end_date}'
    But when I am running the report with entering two dates, I am getting this error:
    *State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 46046] Datetime value 12/1/2010 does not match the specified format. (HY000)*
    I entered 12/01/2010 as start date and 12/02/2010 as end_date
    Can you please guide me in this issue.

    I think your date format is in different format with the date format u stored in presentation variable so better check the date format of the case function u wrote it in you variable that will solve the problem.

  • Currency display issue in the report

    Hello Experts,
    I am facing an issue with the currency type CLP(Chilian Peso).
    It  is noted that  the CLP currency doesn't use decimals.
    In BW reports the values in Local Currency are not OK.
    For example , the right value is 150.755 CLP in R3 side But in the BW report the value is 15.075.500, 00 CLP which is misleading.
    Could any one help me how to solve this issue.
    In TCURX the following settings are maintained
    currency type    decimal
    CLP                       0
    Regards

    Hi Nivas,
    I think following things are happening.
    u2022     Updating The Amount Value into BW data target.
    When we load the data into BW having amount field in it ,it checks for the TCURX table for the currency entry.
    If the currency entry is present in TCURX table it divides the amount by 10**(2-CURRDEC entry in TCURX table)).
    u2022     Displaying the amount into BEx reports.
    The exactly converse happens while displaying such values in the report output,The amount values will be multiplied by 10**(2-(CURRDEC entry in TCURX table)) while diplaying the report output.
    Please check below thread,
    Here is the link for your reference:
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/600aa67b-c348-2b10-f690-aaa81d12ec6a
    Regards,
    Deepak Chavan.
    Edited by: Deepak Chavan on Aug 22, 2008 4:30 AM

  • Master data not present in the reporting cube

    Dear Experts,
    There is a scenario in report design for me.
    I have already created the Bex report and all the fields as mentioned are in the  sales report.
    Client now wants to include two more fields in the report.
    One is the keyfig  " Net value" which is present in the sales cube  and i have already included in the report
    and another field which is master data  0profit_center  is not present in the cube.
    Any ideas how can i include this  0profit center  data  so that i can display in the report?
    As far as i understand, I need to include this master data in the sales  Infocube which is being used for reporting.
    But i am pondering  upon the impact on the system because of this.
    Now i have checked the BI system and the ECC table. In VBRP table of ECC,  the profit center is present.
    But when i see in BI the profit center is not being loaded  from ECC but from flat file source system.
    So i am confused how to go forward.
    Can anyone suggest me  what should be my approach?
    Best Regards!!

    You didn't understand what we suggested.
    Rather than checking 0profit_ctr master data, you need to find the info objects(which are part of your cube) which have master data. in those 0profit_ctr can be a attribute. if yes then navigation settings will work.
    if not then you can add 0profit_ctr to info cube and user master data look up thru routine or option read from master data(bw 7.3).
    Other wise, directly add 0profit_ctr to your flat file data source(and cube) and maintain data thru flat file.
    To look up your cube and 0pfirt_ctr need to have relations with another info objects other wise not possible.

  • Data Displaying issue in ALV report

    Hi,
      I have made a ALV report,  the presetn display layout is as below
    it is displaying the material shortage reprot against issued production order
    ORDER NO.     Order Qty.     MATERIAL     TOTAL QTY     SHORTAGE QTY
    3000000     100     610     100     5
    3000000     100     101     200     43
    3000000     100     8795     400     400
    3000000     100     456     100     67
    3000001     50     548     50     33
    3000004     62     710     62     3
    3000005     15     7895     15     15
    3000020     11     456     22     10
    now the user requirement is the report should come as per below formate
    AT EACH NEW ORDER NUMBER :
    ****************first display main order no. and order qty.
    ORDER NO.     Order Qty
    3000000     100
    ************************then below this display the indiviual material and qty.
    MATERIAL     TOTAL QTY          SHORTAGE QTY
         610            100                     5
       101              200     43
    8795     400     400
    456     100     67
    *******again at new order******
    ORDER NO.       Order Qty
      3000001         50
    **********then below display the items
    MATERIAL     TOTAL QTY          SHORTAGE QTY
      548           50                 33
    how to do this is there any output layout with this i can get this formate in LAV report
    regards,
      zafar

    Hi Zafar,
    You can populate your internal table as per the requirement.
    at new order only.
    itab-Order = 3000000 .
    itab-Order quantity = 100.
    append itab
    for all materials for that order
    itab-MATERIAL       =   610 .
    itab-TOTAL QTY  = 100 .
    itab-SHORTAGE QTY = 5.
    append itab.
    Cheers,
    Suhail

  • Date Format Issue IN BEX REPORT

    Hi Experts,
    we are working on BW 3.5.
    we have a ODS where data is uploaded through flat file and there are 5 to 7 date field all made of Z infoobjects.
    So now the user is putting the data for these Date fields as 20110901 = 1st sep2011. but in report its coming as 09/01/2011
    when i checked all the Z fields that are created for this date fields have reference character as Date
    only one field is character so it is coming correct as given by the user
    but rest all are appearing in different format . In ODS also the date is coming as 09/01/2011
    now the user want all the data to be in the same format as given by HIM.
    I cant even change the properties of these Z info object removing the reference info object 0Date and make them character string.
    so now please suggest how to upload the date given by the user as it is without changing the format and also how to change the format for the back data as its flat file so No data can be deleted.
    thankkkkkkkks

    hello
    Bex analyzer is an excel add-in. Date formats are based on your regional settings.
    If you want to have a different date format in the sap gui then you have to change your user profile in sap system.
    Flat file upload needs the date format in a database format (YYYYMMDD).
    You can transform the date in the transformation step with rules or with a routine( abap coding).
    Thank you
    Yiannis

  • Issue in the report after bookmarking it

    Hi Experts,
    We have WAD reports built on 3.X Query Designer.
    The issue here is:
    The filter values are getting deleted after bookmarking in a report.
    For Ex:
    There are 10 employees displaying in a report and I have filtered 2 employees (using employee number on Employee variable) out of 10. After that if I click on bookmark button a new URL is getting generated but the filter on employees is getting deleted and finally the report is showing 10 employees and not 2.
    Note:
    The issue is happening only for this Employee variable and if I do the same process on other variables they are working fine after bookmarking.
    If you have any idea on how to resolve this issue then kindly share me.
    Chandra.

    Add &VARIABLES_CLEAR = FALSE to end of the URL
    or Check in your WAD for the following commands and add this command at the bottom as shown below. 
    <object>
             <param name="OWNER" value="SAP_BW"/>
             <param name="CMD" value="SET_PROPERTIES"/>
             <param name="TEMPLATE_ID" value=""/>
             <param name="VARIABLES_CLEAR" value=""/>

  • Please help me to solve this date comparision issue..

    Please help me to solve this issue..
    If i have some data like the following..
    ID           START DATE             END DATE
    1             20080101              20080501
    1             20080502              20080630
    2             20080631              20080801
    2             20080802              20080901
                                                 ---------------> There is a break in date over here
    2             20080930              20081029
    2             20081030              20081130
    I need to compare the End Date with the start date (These data will not be in order)
    and find out if there is any break and should get the output date : *20080930*
    I am trying to do this in SQL or PL/SQL.Please help me .
    Thanks in advance.
    phani

    Hi Frank ,
    Sorry to bug you again. I ran your code on my actual data but not gettting the expected output.Here i am posting the actual code and the output that i got when i ran your code.Please bear with me and help me to solve this..
    /* Formatted on 5/25/2009 2:27:24 PM (QP5 v5.115.810.9015) */
    SELECT   member_nbr,
             aff_nbr,
             ymdeff,
             ymdend,
             gap_before,
             COUNT (gap_after)
                OVER (PARTITION BY member_nbr, aff_nbr ORDER BY ymdend DESC)
                AS gap_cnt
      FROM   (SELECT   member_nbr,
                       aff_nbr,
                       ymdeff,
                       ymdend,
                       CASE
                          WHEN ymdeff >
                                  LEAD(ymdend)
                                     OVER (PARTITION BY member_nbr, aff_nbr
                                           ORDER BY ymdend DESC)
                                  + 1
                          THEN
                             1
                       END
                          AS gap_before,
                       CASE
                          WHEN ymdend <
                                  LAG(ymdeff)
                                     OVER (PARTITION BY member_nbr, aff_nbr
                                           ORDER BY ymdend DESC)
                                  - 1
                          THEN
                             1
                       END
                          AS gap_after
    ------------I need this SQL to filter the whole data to the data that i posted in previous post -----
                FROM   (  SELECT   ms1.member_nbr, 
                                   ms1.aff_nbr,
                                   ms1.ymdeff,
                                   ms1.ymdend,
                                   ms1.void
                            FROM   (SELECT   ms.member_nbr,
                                             ms.aff_nbr,
                                             ms.ymdeff,
                                             ms.ymdend,
                                             ms.void
                                      FROM   MEMBER mb, member_span ms
                                     WHERE   mb.member_nbr = ms.member_nbr
                                             AND (20090523 BETWEEN ms.ymdeff
                                                               AND  ms.ymdend
                                                  AND TRIM (void) IS NULL)
                                             AND mb.member_nbr = 'A1000073000 ')
                                   eff_pcp,
                                   member_span ms1
                           WHERE   ms1.member_nbr = eff_pcp.member_nbr
                                   AND (SUBSTR (eff_pcp.aff_nbr, 1, 6) =
                                           SUBSTR (ms1.aff_nbr, 1, 6))
                        ORDER BY   ms1.ymdeff DESC)
    ---------- end of my part  ----------
                table_x) got_gaps;Outputs that i got when i ran that code for each individual members..
    Sorry to bug you frank and thanks for all the help.I will post here if i get any other data.
    Thanks
    phani

  • FAGLL03- Entry Date showing blank in the report

    Hi Gurus,
    We have observed that the field "Entry Date" in the GL report FAGLL03 is not showing entry dates of documents posted . We are using ECC6.0 and CUPDT field is already there in the report FAGLL03.
    Need advise how to achieve this? is there any sap note available for the same
    Regards,
    Vijay

    Thanks for your quick responce.
    I have one question.
    The standard layout of report FAGLL03 is having the field ENTRY DATE.
    Still is it require to maintain as special field in customization under below path? to get values(i.e. Entray Dates)  in the report.
    Path is: SPRO->Financial Accounting (New)->General Ledger Accounting (New)->Master Data->G/L Accounts->Line Items
    ->Define Special Fields for Line Item Display.
    BKPF-CUPDT-Entry Date
    Regards
    Vijay.
    Edited by: Vijaya kumar on Jun 24, 2010 7:19 AM

  • Message "No applicable data found" after executing the report

    Hi all,
    I have 60 records in a cube which is extracted from a function module. I am able to see the data in the cube but when I execute the report I am getting the message u201CNo applicable data foundu201D. Why is that so?
    Can any one please explain me what to do to bring data when the report is executed?
    When I execute the query there is only one field selection criteria 0P_FPVANT and this is mandatory. When I checked the data in the cube I didn't find any field 0P_FPVANT but I found a field Fiscal Period Variant with the technical name, 0FISPER
    I executed the query in RSRT and there also I am getting the same message, "No applicable data found".
    Please advise what do I need to do inorder to get data when the report is executed?
    Thank you.
    Regards,
    Pavan.

    I think so.
    Ok let me take the other report 0FIAR_C02_Q1003. For this report the selection criteria is
    Company code,
    Customer and
    Period/Fiscal Year
    Of these only company code is mandatory. In the data in the cube I see that for co. code BP01 data is available. So I executed the report with co. code as BP01 but no data.
    Then I gave co. code BP01 and Period /Fiscal year as 2008, 2008.03, still I see no data.
    I tried with values in all the fields that are available in cube
    co. code - BP01
    Customer - PCS-C10
    Period/Fiscal Year - 2008011
    Now with respect to Period/Fiscal Year selection field in report, in cube there are 4 columns
    Fiscal Year Period,
    Posting Period,
    Fiscal Year Variant and
    Fiscal Year
    I've tried all of them but when I enter values in all the fields still I am getting the same error, "no applicable data found".
    Please advise.
    Thank you.
    Pavan.

  • Date Format  changes in  the Reporting side..

    Hi friends,
    I have one date field that is Keyfigure (not a Time charecterstic) ...now i want to display date in DD- MON - YYYY format... but up to modelling side my date format is DD.MM.YYYY.....
    i dont want to change in modelling side.. because.. this required format is needed only for some querys ...
    so, can any one suggest me is there any chance to get the date format in the reporting side like this..(27-JAN-2007) ..
    helpful answers will be appriciated..
    Thanks
    Babu

    Hi Babu,
    If the format is required in the Bex analyser then its system dependent setting .
    Control panel - > Regional & language options -> Regional options -> Customize -> Date -> Short Date format -> DD-MMM-YYYY(Change) .
    Do not forget to log off and re-login into bex,execute queries and see the output.
    Hope that helps.
    Regards
    Mr Kapadia
    Assigning points is the way to say thanks in SDN.

Maybe you are looking for

  • VERIZON ARE A BUNCH OF CRIMINALS

    My complaint letter to Verizon Headquarters says it all: I have Verizon FIOS bundle service at my place of residence, which includes TV, phone, and internet.  On September 27 during the night we experienced a power surge.  The Verizon wall unit with

  • Can I call .m files from a LabVIEW executable without the full developmen​t version of matlab installed?

    I have an executable that I am trying to build (and distribute).  Right now, it has Matlab script nodes that call some matlab .m scripts that someone else wrote.  The target PC will not have the full development version of Matlab installed.  Would th

  • Raw Files in Lightroom...

    I just imported RAW files into Lightroom and want to use the Develop tool. However, when I change modules to "Develop" It does not allow me to see the changes as I work. Only when I go back to the Library module can I see them. I need to see real tim

  • Runtimr error OBJECTS_OBJREF_NOT_ASSIGNED when i schedule pgm in back grd

    Hi All when I schedule any BDC pgm in Background by giving job name in SM36 . It is giving an runtimr error OBJECTS_OBJREF_NOT_ASSIGNED and Exception CX_SY_REF_IS_INITIAL . Error analysis An exception occurred that is explained in detail below. The e

  • Needed to update 4000 entries in T510

    Dear experts, Do you know if exists any tool/report to update T510? I have to update 4000 entries, so I would appreciate very much you help! Thanks in advance, Maria