Friday, 28 April 2020
Hello Pentahomaniacs!
Surely at some point in your journeys with Pentaho you will have encountered the problem of loading a file into memory and, when trying, you have found in the transformation a very useful step called “load file content in memory”; However, this step if it is not properly configured will step on everything we have in memory until that moment and will replace it with the content of the file.
But don’t worry, it has a very simple solution, you just have to load the content in a variable defined above.
Within the configuration of the step (by clicking twice on it), in the “File” tab, in the “Dynamic Filename” section you must check the check called “Filename is defined in a field?” and select a variable that you have loaded before with the address of the file in question. In addition, in this way you will be saving the content of this file as a column of a row, which is very useful to make transformations that perform several actions with several rows.
And that’s it, from now on you can load all the files in memory you want without any problem.
Until the next Pentahomaniacs!
