The requirement is to create a web form that uses text data and also some data retrieved from an Excel workbook. Can I do this in the data mapper, or is this more likely a job for Workflow and some scripting?
thanks
Lou
The requirement is to create a web form that uses text data and also some data retrieved from an Excel workbook. Can I do this in the data mapper, or is this more likely a job for Workflow and some scripting?
thanks
Lou
Hello Lou,
This would require both the Workflow and the DataMapper. The issue here is that you cannot create a DM based on two files. I would use the Automation option within Properties/Scope in order to extract that Excel data (CSV) into your DataMapper which would be based off your text data file.
Automation: Automation properties initialize variables coming from the PlanetPress Workflow automation tool. The name of the property needs to be the same as the variable name in Workflow, and they can be either a Local variable or a Global variable. For either one, only the actual name is to be used, so for %{MyLocalVar} use only MyLocalVar , and for %{global.MyGlobalVar} use MyGlobalVar. If a global and a local variable have the same name ( %{myvar} and %{global.myvar} ), the local variable’s value is used and the global one is ignored. To access a workflow variable inside of any JavaScript code within the Data Mapping Configuration, use automation.variables.variablename
You would obviously need to filter out any unrelevant data from the CSV file that doesnt pertain to that record. Therefore some logic would definitely be required within the Workflow.
There perhaps are other ways to approach this problem but this is one suggestion, open up a ticket with us at support if you would like any assistance.
Thanks!
Francis Ciroi
I didn’t mention it but essentially you would store the CSV data for the record within either a Job Info or Variable and then pass that in to the Datamapper. Treating the text file only one record at a time (through a splitter), you always pass in the same variable, overwriting it in your process each time you sequence your text data.