+ Reply to Thread
Results 1 to 4 of 4

How to concatenate upper case of substrings?

  1. #1
    Registered User
    Join Date
    09-02-2010
    Location
    DC suburbs
    MS-Off Ver
    Excel 2003
    Posts
    3

    How to concatenate upper case of substrings?

    I have 2 columns with headers First Name and Last Name
    how would I take
    first 4 characters of First Name, first 4 characters of Last Name, change to uppercase, and then concatenate into a new column Photo Name

    In a statistical package, this does it: multiple lines only need for readability
    string PhotoName(A14).
    COMPUTE PhotoName= CONCAT(
    (upcase(char.substr(Lastname,1,4))),
    (upcase(char.substr(Firstname,1,4))),
    '01.jpg').



    Last Name First Name Photo Name
    Smith John SMITJOHN01.jpg
    Doe Janet DOE JANE01.jpg
    Washington George WASHGEOR01.JPG
    Last edited by AliGW; 12-29-2020 at 05:39 PM.

  2. #2
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,737

    Re: How to concatenate upper case of substrings?

    A sample spreadsheet with expected results would help as per the yellow banner above
    is the name all in 1 cell
    and ONLY 2 names first and last separated by a space
    If the first name is 2 character
    Jo Fred
    then what would the first 4 characters be
    JO F
    and say the name is 3 x 3 Sox Joe
    Wayne
    if my assistance has helped, and only if you wish to , there is an "* Add Reputation" on the left hand side - you can add to my reputation here

    If you have a solution to your thread - Please mark your thread solved do the following: >
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  3. #3
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: How to concatenate upper case of substrings?

    If Names are in A1 and B1 then

    Formula for C1 =upper(left(A1,4))& upper(left(B1,4))
    My General Rules if you want my help. Not aimed at any person in particular:

    1. Please Make Requests not demands, none of us get paid here.

    2. Check back on your post regularly. I will not return to a post after 4 days.
    If it is not important to you then it definitely is not important to me.

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,762

    Re: How to concatenate upper case of substrings?

    If you have no further need of help, then please mark the thread as solved, but don’t post-edit your posts.

    I will mark this as solved for you today to avoid wasting our members’ time.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

+ 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. [SOLVED] Change name format including adjusting upper case to lower case
    By johnmitch38 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 07-26-2019, 07:53 AM
  2. Replies: 1
    Last Post: 07-14-2016, 05:51 AM
  3. Replies: 7
    Last Post: 04-18-2014, 04:11 PM
  4. [SOLVED] Lower Case to Upper Case but No Auto Correction : Solved by Mod (6StringJazzer)
    By HaroonSid in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 03-27-2014, 10:44 AM
  5. Write a subroutine in a module to change case upon exit of a cell to upper case
    By Stephd22 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-15-2013, 06:39 PM
  6. Replies: 14
    Last Post: 08-25-2005, 10:05 PM
  7. Replies: 1
    Last Post: 03-09-2005, 05:06 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