+ Reply to Thread
Results 1 to 12 of 12

forumla that takes into account the year to recognizes the year

  1. #1
    Registered User
    Join Date
    01-23-2014
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    66

    forumla that takes into account the year to recognizes the year

    Hi all,

    need to your help so thank you in advanced!

    Context;-

    i download circa. 40,000 lines worth of data for revenue (columns A to N) with most of the data comes up with a specific period per service stated in the item description field (column I).

    Using that date i try to work the value i need to release into the month (column X), the value i need to defer (column W) and what element of what is released relates to a prior period (column Z).

    From column P to V i've created some formulas to pick up the relevant data and separated the start month, end month, start year, end year. Then I've created some formula using IF to calculate the deferred, released and back-dated amount. The current formulas work great if all the data is in the same year however it falls down when the data relates to a different year.

    i think the current formula just needs to incorporate the year in it somehow but im struggling as going up my own proverbial!

    any help would be great!
    Attached Files Attached Files
    Last edited by moe1986; 12-15-2018 at 09:24 AM.

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: forumla that takes into account the year to recognizes the year

    Instead of breaking a date down into a month number and a two digit year as in W1 & Z1, just enter any daye in the month you're interested in. e.g. put 1/11/2018 in U1

    Then W2 becomes

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    and in Z2
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,587

    Re: forumla that takes into account the year to recognizes the year

    Formulas in columns Q and R derive the date in text format but it should be in date format.
    Try this formulas
    In Q3 then copy down

    =IFERROR(DATEVALUE(LEFT(P3,8)),"")

    In R3 then copy down

    =IFERROR(DATEVALUE(RIGHT(P3,8)),"")


    In S3 then copy down up to column T

    =IFERROR(MONTH(Q3),"")

    In U3 then copy down up to column V

    =IFERROR(YEAR(Q3),"")
    Attached Files Attached Files
    Pl note
    Array formula should be confirmed with Ctrl+Shift+Enter keys together.
    If answere is satisfactory press * to add reputation.

  4. #4
    Registered User
    Join Date
    01-23-2014
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    66

    Re: forumla that takes into account the year to recognizes the year

    Thanks both. for columns S to V i can get the dates however it's really the formulas in W,X and Z im really looking for.

    The current formulas work fine if the Period in from 01.01.2018 to 31.12.2018 however minute the end day is in a future period (or start period is back-dated for that matter) the current formulas break down as in rows 5,6,7.

    Need to modify the formulas to take into account the start year and end year so it automatically calculates what should be recognized for the current month/year

  5. #5
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: forumla that takes into account the year to recognizes the year

    The formula I gave you will only 'break down' if the date I suggested in say U1 is before the end date in column R.
    I have assumed that you are wanting a multiple of the number of months between some start date that you define, (currently you use a month number and a two digit year number) and the column R end date.

    If so please advise what you want to see if the start date is prior to the end date.
    Trivially you could wrap the formula I gave you in an =IFERROR() function to show a blank

  6. #6
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,587

    Re: forumla that takes into account the year to recognizes the year

    In W3 then copy down

    =IF(S3>$W$1,G3,IF(T3+12*(V3-(2000+$Z$1))<$W$1,0,((T3-$W$1)+12*(V3-(2000+$Z$1)))*(J3*K3)))
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    01-23-2014
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    66

    Re: forumla that takes into account the year to recognizes the year

    Quote Originally Posted by kvsrinivasamurthy View Post
    In W3 then copy down

    =IF(S3>$W$1,G3,IF(T3+12*(V3-(2000+$Z$1))<$W$1,0,((T3-$W$1)+12*(V3-(2000+$Z$1)))*(J3*K3)))
    really good! thank you. there is however a scenario where that wouldn't work. please find attached (put in row 9)

    It's when you have a future date however the invoiced amount (column G) is part invoiced (as we are only going to invoice up till the middle of the month) so the deferred amount of column K*column J (monthly price*qty) would not be correct in that case it should equal the invoiced amount.excel help 15.12.18 - deferred v2.xlsx

  8. #8
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,587

    Re: forumla that takes into account the year to recognizes the year

    Year selected is 18 in AA1 but the year in Row 9 is 19.Even then does it treated as part of the month?
    Also I feel if the date in column R is not the end day of the month in X1 irrespective of the year , it should take the invoice amount in Column G.Is this correct.
    Last edited by kvsrinivasamurthy; 12-16-2018 at 12:05 AM.

  9. #9
    Registered User
    Join Date
    01-23-2014
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    66

    Re: forumla that takes into account the year to recognizes the year

    hi kvsrinivasamurthy, see below

    Year selected is 18 in AA1 but the year in Row 9 is 19.Even then does it treated as part of the month?
    No, the paramater's are X1 for the month and AA for the year. If the invoice period e.g. Q9 and R9 are greater than that parameter it should all be deffered (X9)

    Also I feel if the date in column R is not the end day of the month in X1 irrespective of the year , it should take the invoice amount in Column G.Is this correct.
    Yes that’s correct. If column R is not end of the month and the periof is greater than the parameters stated in X1 and AA1 then It should take coulmn G

  10. #10
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: forumla that takes into account the year to recognizes the year

    Just a bit of advice, can I suggest that when wanting to manipulate data that relies on dates youj include a proper date number rather than just two digits from the end of the year. It's more difficult to build a date from that than to use a function to extract the year number digits from a date.

  11. #11
    Registered User
    Join Date
    01-23-2014
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    66

    Re: forumla that takes into account the year to recognizes the year

    noted, thank you.

  12. #12
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,587

    Re: forumla that takes into account the year to recognizes the year

    Sorry for the delay. I am not able to understand clearly what is required.It is better to use dates in columns Q and R rather than the months and dates.
    KVS

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Automatically update year interval cycles from year to year
    By trumptight in forum Word Programming / VBA / Macros
    Replies: 8
    Last Post: 08-21-2014, 10:38 PM
  2. Replies: 3
    Last Post: 11-27-2013, 07:05 AM
  3. Replies: 3
    Last Post: 09-04-2013, 10:49 AM
  4. [SOLVED] How to Sum Cells that comply with a date(month and year) and account ID
    By czhl1 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 08-24-2013, 06:45 PM
  5. Replies: 9
    Last Post: 03-12-2012, 05:30 AM
  6. [SOLVED] money deposited into an account with 6.5% interest-amount of year
    By mathwiz in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 11-02-2005, 06:20 PM
  7. [SOLVED] money deposited into an account with 6.5% interest-amount of year
    By mathwiz in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 11-02-2005, 06:17 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1