Friday, August 26, 2016

How do I combine text in excel sheet to create a sql statement or combine first and last name?

There are two ways to do this... you can use the shortcut or the more formal way:

  • shortcut: =("beginning" & "before column value" & B2 & "after column value and end")
  • formal: =Concatenate("beginning" & "before column value" & B2 & "after column value and end")

  1. Choose the cell where you want to combine the values.
  2. Type in:
    1.  =( 
    2. or 
    3. =Concatenate(
  3. Type in the starting text surrounded by quotes "me" or choose a cell that contains the first text you want to combine like first name.
  4. Type &” “& (a space enclosed in quotation marks).
  5. Type in the next set of text surrounded by quotes "me" or click the next cell with the text that you want to combine like last name.
One other thing I ended up using was the Substitute command as well. It allowed me to replace semicolons with commas for comma delimited exports.

No comments: