CSV_readField ( string ; value )
get's the N-th value in a csv
Average rating: 4.8 (20 votes) Log in to vote
Bert Kraan Allied Pea's http://buffel.org |
If [ CSV_readField ( imported::string ; 1 ) = "Header" ]
Go to Record ....
or
Set Variable [ $Game ; Value:CSV_readField ( imported::string ; 6 )]
true
$Game gets set to "Chess"
Function definition: (Copy & paste into FileMaker's Edit Custom Function window)
We get a csv from another system which needs to be "read"/interpreted and imported into filemaker. Importing is easy using filemaker's "Import Records" script step. After that :
The function enables me to read fields of which I know they contain information so I can put the values in filemaker.
I know which (N-th) field contains the information per the csv definition.
Comments
unix, Japan Jan 4, 2016 |
||
I wonder why do you say the "semi-colon separated value" as CSV. | ||
Bert Kraan, Apeldoorn Jan 5, 2016 |
||
In Europe we use the comma as a decimal separator, and it is custom to separate CSV's using a semicolon. Otherwise differentiating between which comma is a decimal separator and wich is a field separator would be a real challenge. (http://www.digitalpreservation.gov/formats/fdd/fdd000323.shtml) |
||
unix, Japan Jan 6, 2016 |
||
Thanks! | ||
Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.