?
Solved

HOw to parse multiple text data into seperate fields

Posted on 2014-03-12
2
Medium Priority
?
399 Views
Last Modified: 2014-03-12
I am analyzing survey data that I have imported into Access.  One field has multiple text strings (up to six) separated by semi colons.  I am looking for the easiest way to parse this field into multiple fields.  Thanks for any insight.
0
Comment
Question by:Sbovino
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 2000 total points
ID: 39925141
use a function like this

Function fnParseInfo(vString As Variant, idx As Integer, Optional Delimiter As String = ";") As String

   Dim myArray() As String
   myArray = Split(vString, Delimiter)

   If idx < 0 Or idx > UBound(myArray) + 1 Then
      fnParseInfo = "Null"
  Else
      fnParseInfo = myArray(idx - 1)

   End If

End Function

see this similar thread

http://www.experts-exchange.com/Database/MS_Access/Q_28255071.html#a39537854
0
 

Author Closing Comment

by:Sbovino
ID: 39925307
Thanks.  That solved it!
0

Featured Post

Get your Disaster Recovery as a Service basics

Disaster Recovery as a Service is one go-to solution that revolutionizes DR planning. Implementing DRaaS could be an efficient process, easily accessible to non-DR experts. Learn about monitoring, testing, executing failovers and failbacks to ensure a "healthy" DR environment.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Phishing attempts can come in all forms, shapes and sizes. No matter how familiar you think you are with them, always remember to take extra precaution when opening an email with attachments or links.
Preparing an email is something we should all take special care with – especially when the email is for somebody you may not know very well. The pressures of everyday working life stacked with a hectic office environment can make this a real challen…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question