+ Reply to Thread
Results 1 to 14 of 14

how to separate date from specific word

  1. #1
    Registered User
    Join Date
    04-27-2016
    Location
    india
    MS-Off Ver
    2007
    Posts
    87

    how to separate date from specific word

    i have a data like below

    327047534-DD-22-4-16
    327199250-DD-2-5-16
    327199250-DD-2-5-16
    PRI-11458-DD-16-4-16
    PRI-11478-DD-21-4-16
    PRI-11565-DD-27-4-16
    PRI-11565-DD-27-4-16
    PRI-11565-DD-27-4-16
    PRI-11630-DD-2-5-16

    how to separate the date after "DD-"

    attached here with sample file
    Attached Files Attached Files
    Last edited by sharadmaxwell; 05-16-2016 at 04:12 AM.

  2. #2
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    15,592

    Re: which formula to use???

    Your post does not comply with Rule 1 of our Forum RULES. Your post title should accurately and concisely describe your problem, not your anticipated solution.

    Use terms appropriate to a Google search. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will be addressed according to the OP's experience in the forum: If you have less than 10 posts, expect (and respond to) a request to change your thread title. If you have 10 or more posts, expect your post to be locked, so you can start a new thread with an appropriate title.

    To change a Title go to your first post, click EDIT then Go Advanced and change your title, if 2 days have passed ask a moderator to do it for you.

    (This thread should receive no further responses until this moderation request is fulfilled, as per Forum Rule 7)

  3. #3
    Valued Forum Contributor
    Join Date
    01-03-2016
    Location
    Conwy, Wales
    MS-Off Ver
    2016
    Posts
    974

    Re: how to separate date from specific word

    Thank you for amending the title - it is much better when anyone else is trying to search for the same or similar subject.

    one formula that will work (in adjacent cell in row2 and copy down)
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    formatted as follows

    Format Cells.jpg

    this is how it is built up

    formula to extract text.jpg
    Attached Files Attached Files
    If a response has helped then please consider rating it by clicking on *Add Reputation below the post
    When your issue has been resolved don't forget to mark the thread SOLVED (click Thread Tools at top of thread)

  4. #4
    Valued Forum Contributor
    Join Date
    01-03-2016
    Location
    Conwy, Wales
    MS-Off Ver
    2016
    Posts
    974

    Re: how to separate date from specific word

    If the data provided is typical you may get away with

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


    If it is always 13 characters before "-DD-"
    Last edited by Kevin#; 05-13-2016 at 08:10 AM.

  5. #5
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    15,592

    Re: how to separate date from specific word

    This will return last string after DD- regardles number of characters:

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


    This will return date value:

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

  6. #6
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: how to separate date from specific word

    Maybe this...

    =--MID(A1,FIND("DD-",A1)+3,10)

    Format as Date
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  7. #7
    Registered User
    Join Date
    04-27-2016
    Location
    india
    MS-Off Ver
    2007
    Posts
    87

    Re: how to separate date from specific word

    =TRIM(RIGHT(SUBSTITUTE(A1,"DD-",REPT(" ",255)),255))
    above formula is invisible in cell
    but i want
    =TEXT(DATEVALUE(TRIM(RIGHT(SUBSTITUTE(A1,"DD-",REPT(" ",255)),255))),"dd.mm.yyyy")
    above forumla as invisible in cell
    see the attached sample file
    Attached Files Attached Files

  8. #8
    Forum Expert shukla.ankur281190's Avatar
    Join Date
    05-17-2014
    Location
    Lucknow, India
    MS-Off Ver
    Office 365
    Posts
    3,935

    Re: how to separate date from specific word

    Try

    C2=IFERROR(TRIM(RIGHT(SUBSTITUTE(A2,"DD-",REPT(" ",255)),255))+0,"") and the format the cells in date format.
    Last edited by shukla.ankur281190; 05-16-2016 at 03:02 AM. Reason: Clean
    If I helped, Don't forget to add reputation (click on the little star ★ at bottom of this post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)

  9. #9
    Forum Guru samba_ravi's Avatar
    Join Date
    07-26-2011
    Location
    Hyderabad, India
    MS-Off Ver
    Excel 2021
    Posts
    8,913

    Re: how to separate date from specific word

    try
    Please Login or Register  to view this content.
    Samba

    Say thanks to those who have helped you by clicking Add Reputation star.

  10. #10
    Registered User
    Join Date
    04-27-2016
    Location
    india
    MS-Off Ver
    2007
    Posts
    87

    Re: how to separate date from specific word

    Thank you very much experts
    Thanks a Lot
    it solve now

  11. #11
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: how to separate date from specific word

    I'm curious...

    What is the regional date format for India?

  12. #12
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    15,592

    Re: how to separate date from specific word

    According to wiki: https://en.wikipedia.org/wiki/Date_format_by_country

    In India, the DD-MM-YY is the predominant short form of the numeric date usage. Almost all government documents need to be filled up in the DD-MM-YYYY format. An example of DD-MM-YYYY usage is the passport application form.[78][79][80] Though not yet a common practice, the BIS (Bureau of Indian Standards) of the Government of India introduced the standard named "IS 7900:2001 (Revised in 2006) Data Elements And Interchange Formats - Information Interchange - Representation Of Dates And Times" which officially recommends use of the date format YYYYMMDD, for example, 20130910 or 2013 09 10, or 2013-09-10 for the date 10 September 2013

  13. #13
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: how to separate date from specific word

    Thanks for that.

  14. #14
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    15,592

    Re: how to separate date from specific word

    Er body but ya USA, er body but ya

+ 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. Replies: 11
    Last Post: 06-06-2014, 03:34 PM
  2. how to hide formula in formula box, view lookup result in formula box?
    By vengatvj in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-14-2013, 04:06 PM

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