+ Reply to Thread
Results 1 to 2 of 2

Use substring to match record and append suffix

  1. #1
    Registered User
    Join Date
    09-15-2011
    Location
    Oklahoma, USA
    MS-Off Ver
    Excel 2003
    Posts
    1

    Wink Use substring to match record and append suffix

    I have an incredibly easy problem to solve but know nothing of Excel. I have a master file that is 9000 records each 8-character. I want to use a second file that contains a subset of the 9000 records that contain only the first 6-characters:

    Example:

    MasterFile RequestFile

    000001JA 000001
    000002JB 000002
    000003JJ 000005
    000004JA
    000005JB

    What instructions (maybe SUBSTR) will take the 6-char records in the RequestFile and match the corresponding first 6-characters in the MasterFile and produce the result to a OutFile that will list the 8-character record including the JA,JB, or JJ suffix?

    If I ran the 1st record of Request File, 000001 against the MasterFile, it would match the '000001'JA and produce a result record of 000001JA to the Outfile.

    I just need a simple way to add the alpha suffix contained in the masterfile to the 6-char numeric request file records. I knew some TSO CLIST and REXX mainframe but don't have a clue how to code this in WindowsXP or using Excel. If you can help me, I'll gladly pay you $10 in cheeseburgers.

  2. #2
    Forum Expert ConneXionLost's Avatar
    Join Date
    03-11-2009
    Location
    Victoria, Canada
    MS-Off Ver
    2010
    Posts
    2,952

    Re: Use substring to match record and append suffix

    How about:

    Please Login or Register  to view this content.
    Adjust references to suit.

    Cheers,
    Would you like to say thanks? Please click the: " Add Reputation" button, on the grey bar below the post.

+ 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