![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Here is a simple way to import pipe "|" delimited data in Filemaker without the need for a plugin. |
#3
| |||
| |||
|
|
On Jun 27, 6:36 pm, squeed2... (AT) yahoo (DOT) com wrote: Here is a simple way to import pipe "|" delimited data in Filemaker without the need for a plugin. Nicely done. But it seems like using a screwdriver for a hammers job. There are some great command line utilities that can simply replacethe pipes with a comma. sed -i 's/|/,/' filename ok... that might not work as is... the | and , probably need to be escaped. I can't recall offhand if they are special control characters. Plus if commas appear in the actual data, you'd need to deal with those first, e.g. by adding quotes, or just stripping themout, or maybe just converting to tab delimited instead of comma- delimited... sed is included with OS X, and is a free download for windows. I was about to ask what was wrong with using a text editor (lots of |
#4
| |||
| |||
|
|
In article <1183317877.478701.219... (AT) o11g2000prd (DOT) googlegroups.com d-42 <db.pors... (AT) gmail (DOT) com> wrote: On Jun 27, 6:36 pm, squeed2... (AT) yahoo (DOT) com wrote: Here is a simple way to import pipe "|" delimited data in Filemaker without the need for a plugin. Nicely done. But it seems like using a screwdriver for a hammers job. There are some great command line utilities that can simply replacethe pipes with a comma. sed -i 's/|/,/' filename ok... that might not work as is... the | and , probably need to be escaped. I can't recall offhand if they are special control characters. Plus if commas appear in the actual data, you'd need to deal with those first, e.g. by adding quotes, or just stripping themout, or maybe just converting to tab delimited instead of comma- delimited... sed is included with OS X, and is a free download for windows. I was about to ask what was wrong with using a text editor (lots of freebies out there) to replace the pipe with a tab before importing. It then occurred to me that the technique as described can be fully automatic: import, substitute, export, re-import, all from one script. No command lines, no text editors, just a FileMaker script, however you choose to execute it. OTOH, can sed be executed from AppleScript (as Curl can) or VBScript? There would be a shorter method in being able to to that. I have used pipes to delimit multiple script parameters in a Custom Function, and as placeholders in text I'm cleaning up, but have yet to see them used elsewhere. Seems to me such a character would actually be preferable to tabs, commas and quotes, making it possible to have those three in text without being confused for a delimiter. Matt |
#5
| |||
| |||
|
|
Doing it all within filemaker has the advantage that that it is all within filemaker, and that's worth something, its easier to deal with things like error conditions etc, e.g. if the file is missing, or locked or something. |
![]() |
| Thread Tools | |
| Display Modes | |
| |