I’m creating a relationship object to add properties and establish the relationship with the Componentes table.
However, I’m getting an error that expects an array of objects instead of a single object.
My goal: I want the relationship to accept a single object, not an array of objects.
Additionally, in selectcomp, I only have the id of the Componentes.
Could you please guide me on how to modify my code or configure the relationship to work with a single object?
The Bulk Create creates objects from the passed list (objects), if you need to create only one use Save Object block
and then pass it to create relations.
I do not remember if it’s possible to connect to “children” only one object if not you can add a Create List (with single item) between the create relation and save object blocks
When I use the getProperty method to retrieve citynames, it works perfectly when citynames is defined as a block.
However, when I try to retrieve it through a form using an input field, it doesn’t work as expected.
Could you help me identify the source of the problem or let me know if any special configuration is required in this case?
This way, in the developer console, you can compare the data you are passing for creating relations and adjust them to the correct format.
If the form is intended for creating multiple objects, you will need to retrieve their values, create objects that will be saved to the table, and add them to an array, which you will pass to the Bulk Create block. This is because it accepts an array, as indicated by the error you are encountering.