$json.groups

So I’m pulling my hair out, new to N8N and having to dust off my limited javascript skills. So I have a data pull from a vendor, on our users and their assigned groups. I’m going to simply pull these into a table for reporting. I’ve done this a bunch in python.

So we decided it would be a good use case for N8N, of course I run into an odd one. The Data has a sub array named Groups. if I try to rename the field, for another sub array (adminroles) it’s fine. But N8N barfs on Groups

Any Direction would be appreciated,

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

There shouldn’t be anything special about the name “groups”. The workflow below runs fine.

It’s hard to tell what your data structure is from the screenshot. Redacting and posting a sample of the actual JSON would help.

1 Like

I found it.

The first record in the data set has a value set for adminGroups, the same first record does not groups record, so it’s undefined, added ||“” and i’m good.

2 Likes

Don’t forget to mark as solved :slight_smile:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.