I have a simple workflow to import a file. This file is CSV, but it has telephone numbers, possibly with leading zeros. When using the CSV Reader node, this column is automatically labelled as Integer or Double and the leading zeros disappear. Therefore, I want to use the File Reader node, as it allows me to choose the string format for all columns.
Now the files I need to import always have a date stamp and I don’t want to change the file name every time. Therefore, I created this:
The first node finds the file in the folder, using a wildcard where the date stamp is. Result:
The problem is that when I want to select the Flow Variable in the File Reader step, it doesn’t show up. (But I can find the file using the static approach.)
Funnily enough, when I use the CSV reader, the Flow Variable DOES show. I have no clue why.
Who can help me ‘find’ my Flow Variable? Yes, I’ve read other topics, but most of them are about CSV reader and not File Reader. Your help is highly appreciated!
guess you need to convert the variable to string using the /Path to String (Variable) node. The File Reader does not support the new path variable yet.
Hello mldendulk,
you can also use the String to URI node to create a URI (e.g. file:/C:/temp/filestats.csv) from the string path which you can than pass in to the File Reader node. So your workflow would look like this:
We are sorry for the confusion with the new path type that was introduced with the new file handling framework. We haven’t converted all reader and writer nodes as of now but working on in. We are also working on a solution for the CSV Reader to read the telephone numbers as string.
Bye
Tobias