How to cut one column data to two?

G

Gary

Hi,

I want to cut one column data to two base of number of digit and comma,

for example "peter, may, david" cut to 14 digit
column 1 "peter, may,"
column 2 "david"

"peter, may, david" cut to 8 digit
column 1 "peter,"
column 2 " may, david"

Thank!!

Gary
 
R

Rick B

Not sure what exactly you are trying to do. Will you ALWAYS cut at the
eighth digit? I would think you would want to do this based on the location
of the comma, not some arbitrary location.

Are you using Microsoft Access? We don't typically use the term "column" in
Access. That would normally be an Excel term.

Please share more details with us. Are you trying to clean up a
non-normalized database and split the data out? If so, this should be made
into a one-to-many relationship, not multiple columns. When you have a list
of values (in this case several names) you don't place them arbitrarily in
separate fields. Instead, you create a separate related table where you
store each name in a separate record, then you relate that to the main
table.

For example, let's say that your data is a list of students in a class. You
don't want to build a table with 30 "student" fields. Instead, you want one
table to store the class information, and a separate related table with one
record for each student...

TblClass
ClassIDNumber
TeacherID
ClassSubject
ClassRoomNumber
etc.


TblStudents
ClassID
StudentID
StudentFirstName
StudentLastName
Inactive Y/N
etc.


Post back and explain exactly what you hope to store in your database and we
might be able to help you out.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top