Jump to content
Sign in to follow this  
Proprius

Seperating a field into different records

Recommended Posts

Right now, I have a field that sometimes has multiple names entered, each separated by a newline. My goal is that each of these fields has just one name entered, and I'm working on a script that would make a whole new record for each of these extra names. I'm trying to use the Position function find where one name ends and a new one starts, but I don't know what to use for "searchString".

Any ideas? And if there is an easier way of doing this that would be great too. Thanks!

Share this post


Link to post
Share on other sites

Use leftvalues(), rightvalues(), and valuecount() to parse the lines.

Share this post


Link to post
Share on other sites

As Ender stated, you can use those function as well as GetValue (). You would write a loop that would create new records for each parsing and a external loop that would loop through all the records of the set.

BTW. I moved your topic over to Scripts.

Share this post


Link to post
Share on other sites

you can use those function as well as GetValue ()

Hey, even better! I forgot about that one.

Share this post


Link to post
Share on other sites

As Ender stated, you can use those function as well as GetValue (). You would write a loop that would create new records for each parsing and a external loop that would loop through all the records of the set.

I wonder if you might take a look at my post over in Importing and Exporting called "Parsing an imported flat file" and see if you can expand on your recommendations to this person's post. I see the connection but am having problems executing the parsing.

Thanks.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

By using this site, you agree to our Terms of Use.