+ Reply to Thread
Results 1 to 8 of 8

Sorting data based on last 2 digits

  1. #1
    Registered User
    Join Date
    06-04-2015
    Location
    CO
    MS-Off Ver
    2010
    Posts
    19

    Sorting data based on last 2 digits

    Hello,
    I need to link specific data from a workbook to separate sheets.
    I have identification numbers like "1225C51471" where ..71 represents a certain location.

    I have data input from ("B,BA") for each identification number

    I have 8 different 2 digit location identifiers (71,72,84....) and need to sort each identifier from a complete data log to different sheets for each respective location.

    Any help you can offer would be greatly appreciated
    Thank you!

  2. #2
    Forum Expert
    Join Date
    08-02-2013
    Location
    Québec
    MS-Off Ver
    Excel 2003, 2007, 2013
    Posts
    1,414

    Re: Sorting data based on last 2 digits

    Hi and welcome to the forum,

    Can you post a sample workbook with some dummy data and expected results shown.
    GC Excel

    If this post helps, then click the star icon (*) in the bottom left-hand corner of my post to Add reputation.

  3. #3
    Forum Guru Winon's Avatar
    Join Date
    02-20-2007
    Location
    East Rand, R.S.A.
    MS-Off Ver
    2010
    Posts
    6,113

    Re: Sorting data based on last 2 digits

    Hello NoahJEck,

    I have 8 different 2 digit location identifiers (71,72,84....)
    Is there any chance that this may increase to more than only eight in the future? How do you have your Workbook, Sheets and respective locations Set-up?

    One could apply something like; If(Right(A1,2)=71 Then ... Whatever has to happen.


    Please attach a sample workbook.

    Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic

    Regards.
    Please consider:

    Be polite. Thank those who have helped you. Then Click on the star icon in the lower left part of the contributor's post and add Reputation. Cleaning up when you're done. If you are satisfied with the help you have received, then Please do Mark your thread [SOLVED] .

  4. #4
    Registered User
    Join Date
    06-04-2015
    Location
    CO
    MS-Off Ver
    2010
    Posts
    19

    Re: Sorting data based on last 2 digits

    Sample workbook.xlsx

    Sample^

    *Correction from origional post - i have 9 different identification numbers
    I am not sure if anymore will be added or removed in the future.
    I was just thinking i could manipulate the code to adjust for that if it happens.

  5. #5
    Registered User
    Join Date
    06-04-2015
    Location
    CO
    MS-Off Ver
    2010
    Posts
    19

    Re: Sorting data based on last 2 digits

    Sheet 1 represents the complete data log.
    Sheet 2 and 3 represent the data transfer of specific location IDs

  6. #6
    Forum Expert
    Join Date
    05-30-2012
    Location
    The Netherlands
    MS-Off Ver
    Office 365
    Posts
    14,987

    Re: Sorting data based on last 2 digits

    with a pivot table (sorted on location).

    i did not put the data in another sheet.

    see the attached file.
    Notice my main language is not English.

    I appreciate it, if you reply on my solution.

    If you are satisfied with the solution, please mark the question solved.

    You can add reputation by clicking on the star * add reputation.

  7. #7
    Forum Expert skywriter's Avatar
    Join Date
    06-09-2014
    Location
    USA
    MS-Off Ver
    365 Version 2409
    Posts
    2,789

    Re: Sorting data based on last 2 digits

    If you want to run the macro after the first time you run it, make sure you delete the sheets that were created by the macro.
    Attached Files Attached Files
    Last edited by skywriter; 06-04-2015 at 05:09 PM.

  8. #8
    Registered User
    Join Date
    06-04-2015
    Location
    CO
    MS-Off Ver
    2010
    Posts
    19

    Re: Sorting data based on last 2 digits

    Sample workbook.xlsxI really like that idea Skywriter.

    It's almost what im looking for. My sample wb was probably not as helpful as possible so ill make a new one.

    Basically I want there to be a complete data log that is constantly being updated with new data.
    with that data log i would like to be able to view the raw data and graphs with the corresponding inputs.

    from there i would like the data to be broken down and transfered into specific locations.

    When i open the wb, i would like to be able to select any location along with the complete data log

    Here is a better sample that will convey a beter idea of what im looking for.

    Thank you everyone for the help thusfar, i think we are almost there.

    Updated sample: Attachment 399416
    Last edited by NoahJEck; 06-05-2015 at 03:30 PM.

+ 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. Changing digits after decimal to specific digits based on a criteria
    By mpatel000 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 12-28-2012, 02:41 AM
  2. [SOLVED] sorting cell data based on order of digits
    By rosh@excel in forum Excel General
    Replies: 7
    Last Post: 12-12-2012, 02:52 AM
  3. How?-Sorting last digits and not the first
    By jrkaisersr@gmail.com in forum Excel General
    Replies: 5
    Last Post: 07-17-2006, 10:50 AM
  4. data filtering based on last two digits of large number
    By Margo Guda in forum Excel Formulas & Functions
    Replies: 13
    Last Post: 03-19-2006, 11:25 PM
  5. Sorting data by last to digits
    By Brian in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-23-2005, 02: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