Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

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

Recommended Posts

Posted

I have a text file that everyday has to be downloaded from an URL. I need to import the informations from this text file into filemaker, but the data on the text file aren't tab separated, they aren't separated by anything. How can I separate the informations and import them to filemaker automatically ?

Posted

The only way to do this automatically is to determine one or more rules that determine how to separate the data. They may be simple or complicated rules depending on how messy the text file is, but if you can come up with a set of rules that account for every situation, then you can import the data. If you can't define a set of rules then there is no way to automatically import the data.

Some rules might be:

1. Customer name immediately follows the text "Cust Name:"

2. The Customer number may appear anywhere, but is the only 10 digit number in the record.

3. The record is exactly 80 characters long, unless the first character is "X", in which case the length is equal to the square root of the fifteenth number in the third previous record.

If you can provide a bit more information about what the data looks like I maybe I can give some suggestions.

Posted

I'll give you an example of what the text file looks like.

I have the customer name, address, number, start date, end date, vehicle number and vehicle name.

eg.: Jane Smith855 Leverton rd2002080520030805LJK6789HONDACIVIC

As I wrote before these data come always in the same order one satraight after the other. There are no separators. I understood what you explained that if the data are not messy there is a way to automatically import the data , but I have no idea how to do it.

Do you have any suggestions ?

Posted

It's very unusual for there to be no separator of any kind unless the data is arranged so that the fields are a fixed length. Is it possible that your data may actually have some kind of non-printing character as a delimiter? If you want to post an actual file here (or email it to me at [email protected]) I will have a look at it.

  • 4 weeks later...
Posted

If your text is separated by the exact same amount of spaces 100% of the time then you could use a high end text editor like BBEdit that is also scriptable to replace your spaces with the desired separator.

It does this quite well as I've discoverd is really what made me think to mention it.

If you have a very large file or many files, its wornderful.

I use it to Find/Replace text in nearly 2,000 files at once in under 10 seconds.

In this application you can under "Text Options" show the invisible characters.

Certainly you should be able to do this in many other text editor apps, but this one may afford you many more options as I'm finding in "massaging" text files.

This topic is 8038 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
×
×
  • Create New...

Important Information

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