Jump to content

Data pipes instead of tabs/commas


This topic is 7462 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies

I was wondering if anyone had a simple solution (within Filemaker) rather than using Excel to bring in a text file that is delimited by the data pipe (|) character. I'm using a CGI to process form data (MformsPro) on my website, with frequent imports of new data. Mforms produces text files this way, and currently I'm finding and replacing the pipe in BBEdit, or using Excel to do this. I'd like to eliminate the extra step if possible.

Thanks!

Link to comment
Share on other sites

Import as tab delimited. Everything will come into a single field including the pipe delimiters. Call this field "Rawtext".

Have a calculation field called "ReformattedText" with the following formula:

ReformattedText = Substitute(RawText,"|",gTab)

where gTab is a global field that contains a Tab character.

Now export the database as tab delimited with ReformattedText as the only field in the export order.

Finally, re-import this file as tab delimited into the fields that you want.

There are more efficient (but more complicated) ways to do this, but this can be done with fairly simple script steps.

Link to comment
Share on other sites

This topic is 7462 days old. Please don't post here. Open a new topic instead.

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
 Share

×
×
  • Create New...

Important Information

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