I have created the simple SDC pipeline with json as input data.
When i pivot the list item from json, it works fine when list has the elements but its eliminates the records when list is empty
Pivot on revision works but requirements does not produce record
Appreciate any help . Thanks in advance.
"name": "Standard Operating Procedures"
"created": "2020-08-19 15:45:18"
Best answer by mikelsrView original
According to the documentation  the Pivot Field stage creates one record per item in the list or map you are pivoting.
The list being pivoted in the case of `/requirements` has no items, so no records are created.
Feel free to reply if I did not get the question right or if you are looking for some other functionality, in which case we can look for another pipeline design to achieve it.
Thank you for the quick response
I was expecting record with only with non pivoted fields. What is the alternative solution for this situation when list is empty.
If I understood correctly, perhaps we could add another stage to filter out the pivoted fields, and then merge the output records of that stage and the pivot stage like in the following image.
If both stages filter the `/revisions` field you get the following input records in the destination stage:
Is this closer to what you expected? You can find the exported pipeline attached to this message.