I then thought I could get the value returned when mapping the id-numbers to the names, and then print it to the GS row of the content item in question.
The problem is I can’t figure out how to map category names to category ID numers.
In my scenario I’m using the Google Sheet module “Get range values” to look through the list of categories described above. Then I was hoping I could use a “switch” function (or similar) in the subsequent module to map the category ID of a new content item to the corresponding category name.
It turns out, however, that even though the “get range values”-module indeed finds my category names and category id numbers, the subsequent module does not allow me to separate nor dynamically chose among the values returned. It only shows me the labels. Because of this I can’t apply any logic to find the right category.
I could of course “hard code” this as there won’t be that many categories in use, but I also want to use tags which will make a static solution very messy.
Is there something I’m doing wrong here, or is there even a better/smarter way to get to the same hoped for result?
Hi @Jacob1
you can implement your solution by these steps:
list categories from webflow hold it as array then on the spreadsheet instead of insert the category-id
use map() function to get the relevant group name by the group id
get(map({{category-array}};category-name;category-id;{{actual category-id}});1)
you can share here the blueprint if you need extra help
Please note:
I use separate scenarios to sync Webflow items to Google Sheet. This scenario triggers when a new row is created in the main database. The idea with the scenario is to 1) update the new row with a unique identifier (step 2), and then create a new row in the content database (in which I keep more detailed data of each content item).
@Dorian_Ben_Haim KINDLY helped me solve this outside this forum.
The solution was simple: just use the Google Sheet module “Search rows” to search the list of categories. The module has a filter function, with which you can pin down the right variable and its corresponding value.
It’s so great to hear that @Dorian_Ben_Haim was such a great guide in resolving this!
Thank you very much for remembering to share your final solution with the rest of us. This is super valuable and could be incredibly helpful to many others who are searching for similar information.