Automatically translated.View original post

Separate name-surname, still copy one box at a time?

Anyone using Excel to work or report is familiar with this problem.

See you often, like

1) Respondents list do research. Name and last name are in the same box.

2) Staff list files retrieved from the system must be sorted out.

3) Make an honor card or name tag, only want a real name, but the information is the full name

Name and last name are in the same box. Do not copy one by one. Use = TEXTSPLIT (A2, ""). Split in the space. Name in the first box. Surname overflows to the next box. Use in Excel 365. If the older version, use Data > Text to Columns instead.

Formula: = TEXTSPLIT (A2, "")

Separate text in the space. Name down. B. Surname overflows. C itself.

Trick actually used

1) Only the first name is used = TEXTBEFORE (A2, "") and the last name is used = TEXTAFTER (A2, "").

2) Two spaces between names will be inserted. Enter TRUE. Channel 4 = TEXTSPLIT (A2, "," TRUE)

3) Will delete the full title column. Copy the result and paste the Paste Values first. Otherwise, the formula is broken.

Save for use when actually working

Quick work, greet the green house @ 857afhgp

# Excel # Excel formula # textsplit # Work

10/5 Edited to

... Read moreในการทำงานกับข้อมูลรายชื่อที่รวมชื่อและนามสกุลอยู่ในช่องเดียวกัน ผมเองเคยเจอปัญหาการต้องแยกข้อมูลออกมาเป็นช่องต่างๆ ทีละคนด้วยการคัดลอกแบบแมนนวลซึ่งเสียเวลามาก หลังจากได้ลองใช้สูตร =TEXTSPLIT(A2," ") ใน Excel 365 ช่วยแบ่งชื่อกับนามสกุลโดยอัตโนมัติ ทำให้จัดการข้อมูลได้เร็วขึ้นมาก และยังมีสูตรเสริมที่ช่วยแยกชื่อจริงอย่าง =TEXTBEFORE(A2," ") และนามสกุลด้วย =TEXTAFTER(A2," ") ที่ผมมักใช้เมื่อต้องการแค่ข้อมูลบางส่วนอย่างรวดเร็ว สำหรับผู้ใช้ Excel รุ่นเก่า สามารถใช้เมนู Data > Text to Columns ซึ่งก็ถือว่าเป็นวิธีที่ง่ายและไม่ต้องพึ่งสูตร แต่ถ้าจะทำงานแบบออโต้ สูตรเหล่านี้คือทางเลือกที่ดีมาก อีกจุดที่ผมเจอคือต้องระวังเวลาแก้ไขข้อมูล เพราะถ้าเราลบคอลัมน์ชื่อเต็มไปเลยโดยไม่แปลงค่าด้วย Paste Values ก่อน สูตรจะแตกและข้อมูลจะเสียหายได้ เทคนิคนี้ช่วยลดเวลาและลดความผิดพลาดในการจัดการรายชื่อสำหรับงานวิจัย การจัดการพนักงาน หรือการพิมพ์บัตรต่างๆ ผมแนะนำให้เซฟสูตรเก็บไว้ ใช้บ่อยๆ จะช่วยให้งานเร็วและมืออาชีพมากขึ้นแน่นอน ยังไงก็ลองใช้ดู แล้วจะรู้ว่าการจัดการชื่อ-นามสกุลใน Excel ง่ายขึ้นเยอะครับ!