Get Last Invoice Day and No of days based on Invoice date

Hi,
Can you please provide me logic on how to get the Last Invoice day from the invoice dates .
Also want to the know the no. of days in the month based on invoice date,
Thanks,
Pra.

Hi
Getting this information there is few standard functions available. Try to find out & utilize it.
or else you should have to write code in customer exit.
swetha

Similar Messages

  • I have set up mail but it has 37000 mails to load, obviously very old stuff but how do I get rid without loading and deleting, take days?

    I have set up mail but it has 37000 mails to load, obviously very old stuff but how do I get rid without loading and deleting, take days?

    Go under settings, mail, contacts and calendars and then choose only to sync back 50 or 100 or 1000 mails. Chances are you don't really need the old ones on your device and it'll save room (I have mine set to 50)

  • Current day and no of days in current month

    Hi all,
    can anbody tell me which object is used for current day and no of days in current month.

    Hi,
    USe /OSP/GET_DAYS_IN_MONTH Function Module, just give Date you will get No. Of days in that Month.
    Use SY-DATUM for current date.
    Ex:
    Data: dt type SY-DATUM.
    dt = SY-DATUM.
    so you get current date in dt.
    Thanks
    Reddy

  • February is 29 days and offset -365 days offset is wrong

    Hello
    I have many key figures calculating offset periods of -365 days on 0calday interval
    Today I have a problem because february is 29 days and all values with the offsets on 01.Feb.2008 until 29.02.2008 are reading/summing up the values for 01.Feb.2007 until 01.March.2007. 
    Is there a way to solve this without having to change the offsets in all key figures in all queries to -366?
    Thanks in advance
    Heloísa
    Edited by: Heloísa Alves on Mar 5, 2008 10:48 AM

    Dear,
    Try to create a variable with User Exit----
    >  in that give the logic as Prevoius year to date...consult with ur ABAPer to write the logic and use that variable in ur queries then only the problem will get resolved ...
    If u find the standard variable then install it and use it ...................
    Regards
    venu

  • Want to display no. of ser. orders closed with in 1 day and outside 1 day

    Hi Experts,
    Im displaying a summary report for Closed call.
    I want to display the Number of Service Orders Closed With in 1 day and Out side 1 day.
    For example:
    Brand......ASP...................With in 1day...............................Outside 1 day
    ABC1........ALPHA Tec...........24................................................5
    BCD2..........BETA Tec.............76................................................7
    The difference of days I have brought using 2 variables (1. is for closed date and 2. is for service order created date)
    In the Formula Variable I have (Subscrated Closed date - Created Date)
    I'm not very sure how to bring the count of the service order that are closed with in 1 day and outside 1day.
    Please help.
    Thanks

    Hi,
    This could be achieved through Data model level as well:
    1. By assuming you have two date char Created date and closing date.
    2. Create a char (On-time) flag and populate flag by ABAP coding if Closing - Created = 1 then field should be Check ("X").
    3. Restrict your report with this Flag to find out number of Service orders on-time.
    4. Define a counter KYF in your data model and maintain fixed value = 1 in your cube / ODS.
    This is one approach let me know if any further information is required.
    Regards,
    Venkat

  • How to get Last Year Sales and YTD Sales without using AGO and TODATE?

    Hi all,
    I have got Company and Time dimensions and Sales Fact. My requirement is to get Last Year sales for each company without using AGO function and YTD without using TODATE function. (Due to performance issue as AGO and TODATE do not insert a Cache entry).
    Can someone please help me to achieve my requirement? Thanks in advance.

    Hi Satya,
    Thanks again for your reply. To start with I don't have data for the years 2012 and 2011 to test as I am using SH sample schema from Oracle. I have applied your solution but it does not seem to be working for the previous years like 2000, 2001. My requirement is to have a dashboard prompt "YEAR" and let the user choose whatever year he wants.
    Please have a look at the column formulas of my analysis (As per your solution) :
    ***here B_YEAR is replaced by CALENDAR_YEAR.  
    Amount: "F1 Sales"."Amount"
    AmountYTD:  FILTER("F1 Sales"."Amount" USING "D1 Time"."CALENDAR_YEAR" =YEAR(CURRENT_DATE))
    Amount LY: FILTER("F1 Sales"."Amount" USING "D1 Time"."CALENDAR_YEAR" =YEAR(CURRENT_DATE)-1)and the physical query generated by BI Server: (as you can see I have got a filter CALENDAR_YEAR= 2000)
    WITH
    SAWITH0 AS (select sum(T1074.AMOUNT_SOLD) as c1,
         sum(case  when T1035.CALENDAR_YEAR = TO_NUMBER(TO_CHAR(TO_DATE('2012-05-03' , 'YYYY-MM-DD'), 'yyyy'), '9999') then T1074.AMOUNT_SOLD end ) as c2,
         sum(case  when TO_NUMBER(TO_CHAR(TO_DATE('2012-05-03' , 'YYYY-MM-DD'), 'yyyy'), '9999') - 1 = T1035.CALENDAR_YEAR then T1074.AMOUNT_SOLD end ) as c3,
         T1035.CALENDAR_MONTH_DESC as c4,
         T1035.CALENDAR_YEAR as c5,
         T1035.CALENDAR_MONTH_ID as c6
    from
         TIMES T1035 /* D1 Time */ ,
         SALES T1074 /* F1 Sales */
    where  ( T1035.CALENDAR_YEAR = 2000 and T1035.TIME_ID = T1074.TIME_ID )
    group by T1035.CALENDAR_MONTH_DESC, T1035.CALENDAR_MONTH_ID, T1035.CALENDAR_YEAR)
    select distinct 0 as c1,
         D1.c4 as c2,
         D1.c5 as c3,
         D1.c1 as c4,
         D1.c2 as c5,
         D1.c3 as c6,
         D1.c6 as c7
    from
         SAWITH0 D1
    order by c3, c2 Thanks in advance.

  • Get Old Value and the new value based on the date

    Hi
    I have a table called roster created below with following insert statements.
    CREATE TABLE ROSTER
    ROSTER_EMPLOYEE_DEF_ID NUMBER,
    EMPLOYEE_ID NUMBER,
    DEFINITION_REGION_CODE NUMBER,
    DEFINITION_DISTRICT_CODE NUMBER,
    DEFINITION_TERRITORY_CODE NUMBER,
    START_DATE DATE,
    END_DATE DATE
    INSERT INTO ROSTER
    (ROSTER_EMPLOYEE_DEF_ID,EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE)
    VALUES
    (1,299,222,333,444,'1-JUN-2011','30-JUN-2011')
    INSERT INTO ROSTER
    (ROSTER_EMPLOYEE_DEF_ID,EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE)
    VALUES
    (2,299,223,334,445,'1-JUL-2011','20-JUL-2011')
    INSERT INTO ROSTER
    (ROSTER_EMPLOYEE_DEF_ID,EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE)
    VALUES
    (3,299,224,335,446,'1-AUG-2011','30-AUG-2011')
    INSERT INTO ROSTER
    (ROSTER_EMPLOYEE_DEF_ID,EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE)
    VALUES
    (4,300,500,400,300,'1-JUN-2011','20-JUN-2011')
    INSERT INTO ROSTER
    (ROSTER_EMPLOYEE_DEF_ID,EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE)
    VALUES
    (5,300,501,401,301,'1-JUL-2011','20-JUL-2011')
    In the above table we have columns like
    EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE
    The result i am looking from the above table is based on the EMPLOYEE_ID OF START_DATE AND END_DATE
    I need to get OLD_DEFINITION_REGION_CODE and the NEW_DEFINITION_CODE
    Similarly OLD_DEFINITION_REGION_CODE and the NEW_DEFINITION_REGION_CODE
    and OLD_DEFINITION_TERRITORY_CODE and the NEW_DEFINITION_TERRITORY_CODE
    I need to get one row of data for each employee saying old value and new value
    for employee 299 there are 3 records it must give the new record which is the latest date i.e start date 1-aug-2011 and end date 30-aug-2011 old record will be
    start date 1-jul-2011 and 20-jul-2011
    For the above table data i need to get the data as below
    EMPLOYEE_ID OLD_DEFINITION_REGION_CODE NEW_DEFINITION_CODE OLD_DEFINITION_REGION_CODE NEW_DEFINITION_REGION_CODE START_DATE END_DATE
    299 223 224 334 335 20-JUL-11 30-AUG-11
    300 500 501 400 401 20-JUN-11 20-JUL-11
    Please suggest me to get the above result based on the data. Please let me know if my posts are not clear
    Thanks
    Sudhir

    SELECT  EMPLOYEE_ID,
            OLD_DEFINITION_REGION_CODE,
            NEW_DEFINITION_REGION_CODE,
            OLD_DEFINITION_DISTRICT_CODE,
            NEW_DEFINITION_DISTRICT_CODE,
            OLD_DEFINITION_TERRITORY_CODE,
            NEW_DEFINITION_TERRITORY_CODE,
            START_DATE,
            END_DATE
      FROM  (
             SELECT  EMPLOYEE_ID,
                     ROW_NUMBER() OVER(PARTITION BY EMPLOYEE_ID ORDER BY START_DATE DESC) RN,
                     LAG(DEFINITION_REGION_CODE) OVER(PARTITION BY EMPLOYEE_ID ORDER BY START_DATE) OLD_DEFINITION_REGION_CODE,
                     DEFINITION_REGION_CODE NEW_DEFINITION_REGION_CODE,
                     LAG(DEFINITION_DISTRICT_CODE) OVER(PARTITION BY EMPLOYEE_ID ORDER BY START_DATE) OLD_DEFINITION_DISTRICT_CODE,
                     DEFINITION_DISTRICT_CODE NEW_DEFINITION_DISTRICT_CODE,
                     LAG(DEFINITION_TERRITORY_CODE) OVER(PARTITION BY EMPLOYEE_ID ORDER BY START_DATE) OLD_DEFINITION_TERRITORY_CODE,
                     DEFINITION_TERRITORY_CODE NEW_DEFINITION_TERRITORY_CODE,
                     LAG(END_DATE) OVER(PARTITION BY EMPLOYEE_ID ORDER BY START_DATE) START_DATE,
                     END_DATE
               FROM  ROSTER
      WHERE RN = 1
    EMPLOYEE_ID OLD_DEFINITION_REGION_CODE NEW_DEFINITION_REGION_CODE OLD_DEFINITION_DISTRICT_CODE NEW_DEFINITION_DISTRICT_CODE OLD_DEFINITION_TERRITORY_CODE NEW_DEFINITION_TERRITORY_CODE START_DAT END_DATE
            299                        223                        224                          334                          335                           445                           446 20-JUL-11 30-AUG-11
            300                        500                        501                          400                          401                           300                           301 20-JUN-11 20-JUL-11
    SQL>  SY.

  • Displaying privious 7 days and net 7 days link in jsp

    hi
    i am using jsp
    in that jsp i vant display only last 7 days details.
    i am getting all values in database and stored in to an arraylist.
    in that arrylist date also onthing.
    according to the date i have to display the 7 days list.
    for that vhat i have to use.I dont know.
    but it is needed very urgent.
    anybody knows help me
    thanks.

    first, you really need to learn to express yourself more clearly - e.g. learning better english. I have no idea what you mean ...

  • I pre-ordered Paramore's new album one day and the next day I received a $15 gift card for itunes and I redeemed it. My question is now that I have redeemed it will itunes take the price of the preordered album from my $15 or from my debit card?

    If not how can I make that happen? The Paramore pre-order is $9.99 and I want itunes to take the money from the gift card and not my bank account. The charge won't happen until the 9th, when it is released.

    I'm kind of running into the same problem with a TV season I bought. I have watched the first 4 episodes just fine but now a new episode is available and it wants me to pay for it. Even though I have already paid for it when I bought the complete season.
    I think they are mucking around in the servers and causing this issue. I have reported the problem through iTunes and I hope they get it fixed soon.
    EDIT: I just want to add that I didn't know AC/DC's new album was out, I'll have to go buy it. Thanks for the heads up on that.

  • Why can't I get my old bookmarks and passwords back using the 'Old Firefox Data' folder?

    Hi,
    Ok.....
    I have just recovered my Samsung laptop back to the day I purchased it (for a fresh start)
    I have the 'Old Firefox Data' folder on an external hard drive that was created a few weeks ago when I refreshed Firefox
    I've tried this many times but with no luck what so ever:
    https://support.mozilla.org/en-US/kb/recovering-important-data-from-an-old-profile
    I've re-installed Firefox 3 times
    I've created new profiles and deleted others
    2 Days down and I'm still can't get any of my bookmarks or passwords etc and for some reason when I create a new profile I can't find it as it's not in the location 'Profile Manager' says it is.
    I'm now total lost and getting stressed out as I really need this data.
    Any help would be very much appreciated.

    Hello,
    Thank you for your reply's.
    I've been able to restore/apply all of my data (bookmarks, passwords etc) on my girl friends computer without any issues at all, therefore it's not something I'm doing wrong.
    I've been so involved with trying to get my profile back on my computer I hadn't noticed that Firefox is not operating as it should, I've found:
    - I'm unable to view/open my profile folder from 'Help > Troubleshooting Information > Profile Directory: Show Folder' (when I click 'Show Folder' nothing happens) however when I go to 'C:\Users\AutoStar\AppData\Roaming\Mozilla\Firefox\Profiles' I can view the data.
    - I'm unable to save any bookmarks
    - Sometimes when I try to close a tab it will not close as such however once the 'x' is clicked I'm then unable to view the page but the tab still stays visible
    As I said I recovered the laptop back to the day I purchased it (for a fresh start) so Firefox was a fresh install I've also uninstalled and re-installed a few times now but the result is always the same.
    Any ideas?

  • Getting the Month value and Name from the Ranges of the Date given input.

    Hi Techies,
    I am developing Monthly wise report in FICO. My Inputs are Company Code, Fiscal Year and Date Range. From the Date Range I have to get the month and Generate the Report.
    For Ex:
    BUKRS : 1000
    GJAHR : 2009
    FKDAT : 01.04.2008 to 01.04.2009
    From the Above Date range how can I get the individual month names or periods. As per my Knowledge I can get the month value when the date is parameter but here the date is ranges.  Is any code available for this ?
    Thanks in Advance
    Regards,
    Muralikrishna Peravali.
    Edited by: muralipsharma on Aug 31, 2010 10:30 AM
    Edited by: muralipsharma on Aug 31, 2010 12:57 PM

    DATA: lv_dat          TYPE dats,
          lv_day          TYPE c LENGTH 2,
          lv_month        TYPE c LENGTH 2,
          lv_year         TYPE c LENGTH 4.
    DATA: lv_poper        TYPE t009b-poper.
    DATA: lt_poper        TYPE TABLE OF t009b-poper.
    SELECT-OPTIONS: so_dat        FOR sy-datum.
    break fis-kemmer.
    lv_dat = so_dat-low.
    DO.
      CLEAR: lv_poper.
      CALL FUNCTION 'FI_PERIOD_DETERMINE'
        EXPORTING
          i_budat        = lv_dat
        IMPORTING
          e_poper        = lv_poper
        EXCEPTIONS
          fiscal_year    = 1
          period         = 2
          period_version = 3
          posting_period = 4
          special_period = 5
          version        = 6
          posting_date   = 7
          OTHERS         = 8.
      APPEND lv_poper TO lt_poper.
      lv_day    = lv_dat+6(2).
      lv_month  = lv_dat+4(2).
      lv_year   = lv_dat(4).
      lv_month = lv_month + 1.
      IF lv_month LE 9.
        CONCATENATE '0' lv_month INTO lv_month.
      ENDIF.
      CONCATENATE lv_year lv_month lv_day INTO lv_dat.
      IF lv_dat GT so_dat-high.
        EXIT.
      ENDIF.
    ENDDO.
    after that you have a list of all the FI periods in internal table LT_POPER.
    get the idea?

  • Getting last day of the month

    hi ,
    is there an existing date funtion to get last day of the month ?
    pls advise
    else
    i'll try to add_month + 1 to current month and format to the first day and minus 1 day from that new month
    tks & rdgs

    last_day function
    <br>
    jeneesh

  • Difference Between Current Day and fist day of the payroll period

    Hi,
    How do i find the difference between the current day and the first day of the payroll period with period parameter XX.
    Operation VARSTFDYXX is used to decide if the current day is the first day of the payroll period. But is there any operation available to check the difference in exact number of days.
    I know hrs=y is used to find difference between current day and a date specification record from IT0041, but i need to check difference between current day and first day from a payroll period parameter.
    Any response is greatly appreciated.
    Thanks,
    Imaneul Rajiv

    No! haven't seen it at all! Do I have to drain the battery completely and then charge it? I did that the first day I bought the phone and yet the stats are the same for me
    PS: I am referring to the Call Time stats and not the Usage/Standby stats

  • Last ten years and 5 years afterwards from Current year

    How can i get last ten years and 5 years afterwards from Current year in a single query which is picking data from dual.

    SQL> select add_months(sysdate, -1 * 10 * 12), add_months(sysdate, 5 * 12) from dual ;
    ADD_MONTHS( ADD_MONTHS(
    14-FEB-1996 14-FEB-2011
    1 row selected.
    SQL>
    [rep]                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Recently when clicking on Safari, it refused to open saying there were some components damaged. It was suggested I backup, remove OSX and reinstall. Now all I get is white screen and apple logo when starting. What to do?l

    I Have an iMac desktop purchased in 2010 with OS X 6.1.6 and Snow Leapard. Recently after starting up, I was not able to open Safari. I checked for updates and all was well. I tried again and got a message saying Safari could not be opened because some components were damaged. After using Disk utilities to try and repair, it was suggested I uninstall OS X and reinstall from the disk. I did not at the time because I wanted to backup some info to a USB drive. But now when I startup all I get is the white screen and Apple logo and the loading symbol. What happened and How can Imfix it? I am not very tech savvy and don't know where to turn!

    Hi nancy mfromamity harbor,
    Welcome to the Support Communities! It sounds like reinstalling the Snow Leopard operating system is your next step.  This should not affect the documents and data that you currently have on your iMac. I'll include the information to show you how below.
    Mac OS X 10.6: Reinstalling Mac OS X
    http://support.apple.com/kb/PH6606
    Under some circumstances, you may need to reinstall Mac OS X. You can reinstall Mac OS X while keeping your files and user settings intact.
    Note:To reinstall Mac OS X from another computer on your network, see:
    Using another computer’s DVD or CD drive 
    To reinstall Mac OS X:
    Insert the Mac OS X installation disc and double-click the Install Mac OS X icon.
    Follow the onscreen instructions. In the pane where you select a disk, select your current Mac OS X disk (in most cases, it will be the only one available).
    If you want to control which parts of Mac OS X are installed, click Customize, and then select the parts you want to install.
    To start the installation, click Install.
    If you purchased a standalone version of Mac OS X, these installation instructions are in a PDF file located on the Mac OS X installation disc.
    If you need to reinstall the version of Mac OS X that was on your computer when you purchased it, or if you need to restore all the software on your computer (including Apple software, third-party applications, and other printer drivers), refer to the documentation that came with your computer.
    If you need to reinstall Mac OS X and you’ve been using Time Machine to back up your applications, files, and user settings, you can easily restore this information from your Time Machine backup disk after you’ve reinstalled Mac OS X.
    Nancy, here is the contact information if you need technical assistance to get your iMac up and running.
    Intel-based iMac - Contact Support - Apple Support
    http://www.apple.com/support/imac/intel/contact/
    Good luck!
    - Judy

Maybe you are looking for

  • Share map issue

    Succeeded once in creating a map with 8 images Tried again different location but map of Japan appears instead of actual location error on page appears bottom left corner Using Elements 8 with win 7 64 bit machine Any assistance would be appreciated

  • Using rowid in ref cursor

    Hi, I want to use rowid for updating the rows in the ref cursor. My code looks like below: DECLARE emp_refcursor SYS_REFCURSOR; emp_rec employee%ROWTYPE; l_run_id NUMBER; lv_sql_stmt VARCHAR2(4000) := 'SELECT a.* FROM employee a where a.run_id = :l_r

  • FTP, adding documents

    I have a site set up (Manage Sites) through FTP. I want to add in documents from my harddrive to the website, but I don't know how, I guess. I dragged the file from my disc to the website (in the Files list) and it didn't show up, even though I refre

  • Music Background in Slideshow

    I have taken the Flash Slideshow template and altered it to fit my design. I would like to add three songs to play continuously in the background. The problem is, I can only loop one song at a time. How can I loop three songs to play as long as the s

  • HT4199 I am using hotel's wi-fi and cannot go to them and ask to change their password as my ipad cannot accept it because it is too short!

    The button 'join' is greyed out. I guess because the password is too short, 7 characters. The password is correct as I am using it on another device but want to use iPad and this is really not helpful.