+ Reply to Thread
Results 1 to 5 of 5

Summing numerical substrings.

  1. #1
    zilfar@yahoo.com
    Guest

    date calculation in Excel

    I tried to do date calculation in excel but seems like couldnt get the result which I want.I extracted data from SAP with a standard date being 12.02.2004 when I paste it into the Excel and tried to do the calculation eg. 12.12.2005 - 12.02.2004 in Excel.it gives me and error message.

    How am I going to make sure that the substraction between these two dates will give me and answer in days.

    Pls note that I am a layman in using Excel formulas.fyi i dont want to change the date to 12/02/05 instead I would prefer it to be as waht I originally received it.

    Pls help.Thanks in advance.

    Zilfar

  2. #2
    Vinay
    Guest

    Easier way to do this

    =VALUE(LEFT(B2, LEN(B2)-2)) and sum it all

  3. #3
    Forum Contributor
    Join Date
    12-07-2004
    Posts
    596

    Summing numerical substrings.

    Problem:

    Listed in columns A:B are file names and their sizes (KB, MB or GB).
    How could we total MB file sizes only?

    Solution:

    Using the FIND and LEFT text category functions, in the following Array formula:
    {=SUM(IF(ISNUMBER(FIND(C8,B2:B5)),VALUE(LEFT(B2:B5,FIND(C8,B2:B5)-2)),0))}

    File name______File Size
    file1__________20 MB
    file2__________ 30 KB
    file3__________ 1.2 GB
    file4__________ 400 MB

  4. #4
    Forum Expert oldchippy's Avatar
    Join Date
    02-14-2005
    Location
    Worcester, UK
    MS-Off Ver
    Excel 2007 (Home)
    Posts
    7,097
    OK the Tip works fine, but it would be more beneficial if the process of arriving with the answer could be explained in detail?
    oldchippy
    -------------


    Blessed are those who can give without remembering and take without forgetting

    If you are happy with the help you have received, please click the <--- STAR icon on the left - Thanks.

    Click here >>> Top Excel links for beginners to Experts

    Forum Rules >>>Please don't forget to read these

  5. #5
    Registered User
    Join Date
    03-24-2006
    Posts
    3
    Doesn't the "-2" require you to know in advance how long each of the letter sequences you're removing are? Answer is sorta misleading anyway, since after conversion, it should be around 1600 MB and change (since base 10 is only approximate).

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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