Cannot map fields after iterator

:bullseye: What is your goal?

I need to create a csv to export a file from Snowflake to Box.

:thinking: What is the problem & what have you tried?

In the past, I’ve been able to see the fields from the iterator and then map them into the CSV module. I’ve confirmed that the iterator is processing the columns, as I clicked the white bubble on the top of the iterator module. However, when I add the Advanced CSV module, I cannot map the fields. All I see is Flow Control, Total number of bundles, bundle order position, and Value. I am not able to select my columns. I see that I could type them in manually such as {{2.Source}} but some of my fields have spaces in them, and if I type in {{2.‘Source Type’}} it doesn’t work. Help?

:camera_with_flash: Screenshots (scenario flow, module settings, errors)

Hey there,

Try reloading the scenario to see if they appear. If not, you can type them in manually. Hover over a variable to see it’s raw name and it should be something like {{6.fiscal_year}} for example.

Thank you for your message. I have reloaded the scenario multiple times. To no avail. I would be willing to type in the fields manually, but I have some fieldnames with spaces (“Fiscal Year”) and I need to know the syntax. I have tried spaces, wrapping in extra curly brackets, single quotes, double quotes. Nothing is working.

Hover your mouse over the variable in the previous module and it will tell you the raw name. It’s either fiscal_year or fiscalYear or something of that sort.

It shows as “Fiscal Year.” I also tried renaming the fields in the Snowflake SQL statement

, “Fiscal Year” as Fiscal_Year

and then I typed in the fields names manually {{2.Fiscal_Year}} but in my output all my single-word variables had data and all my renamed fields (like Fiscal_Year) were blank.

Frustrating!

What exactly are you mapping as the output of the Snowflake module in the Iterator?

It looks like the Snowflake module is already producing several bundles with collections as an iterator and you don’t need the Iterator module at all.

The way I am executing this on current exports is
Check the Box folder
If the file exists, change the name and move it
Execute SQL in Snowflake
Iterate by Array > Rows
Create CSV

Upload to Box


I just don’t understand how I am going to get my fieldnames into the CSV module.

Is this a bug or a Support issue?

I finally got this to work. The trick was to run after each step.

A. Add Execute Snowflake SQL and run

B. Add Iterator > Array > Rows and run

C. Add CSV and map the fields

D Add upload to Box

E Add Get Folder Items from Box as step 1 (before Snowflake)

Add update folder items from Box as step 2 (before Snowflake)

Thank you for your help in sleuthing!

2 Likes