<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content
0D54z000091GbpPCASOkta Identity EngineWorkflowsAnswered2024-03-05T05:35:24.000Z2023-04-05T13:25:27.000Z2023-04-10T04:15:57.000Z

HayatoY.21830 (CLARA, Inc.) asked a question.

List-Reduce is errored ... "error": "Duplicate input key: memo"

This error will occur if the name of the receiving item is set to memo in the start event on the helper flow side.

 

I have implemented it with reference to the following documents,

but in each case the name of the helper flow item is memo.

 

Reduce | Okta

https://help.okta.com/wf/ja-jp/Content/Topics/Workflows/function-reference/List/list_reduce.htm

 

How to Reduce a List to a Single Value, 3 Examples Using List-Reduce Workflows Card – Max Katz

https://maxkatz.net/2022/10/20/how-to-reduce-a-list-to-a-single-value-3-examples-using-list-reduce-workflows-card/

 

I don't think it's a type problem because the type of the memo item and the type of each item on the helper flow side are the same type.

 

How can I resolve this error?


  • HayatoY.21830 (CLARA, Inc.)

    I found a post on another community site saying they ran into a similar problem.

    In summary:

    If you run it as a unit test for the card, you will get same error, but if you run the entire flow, it will work fine.

    Please let me know if there is a document that describes this specification(or bug?).

    Is there any case where other functions or usecase have the same problem?

    Expand Post
  • Paul S. (Okta, Inc.)

    Hello @HayatoY.21830 (CLARA, Inc.)​ Thank you for reacting out to our Community!

     

    At this time we recommend not to use the "Test" button as this uses different code/functionality, but we do recommend to test the flow by running it.

     

    Community members help others by clicking Like or Select as Best on responses. Try it today.

    Expand Post
    • HayatoY.21830 (CLARA, Inc.)

      Thank you for your reply. @Paul S. (Okta, Inc.)​ 

      > At this time we recommend not to use the "Test" button as this uses different code/functionality, but we do recommend to test the flow by running it.

       

      Yes, I understood that the single execution of the List-Reduce card is not a single execution in the strict sense because the actual internal processing is processed by calling the helper flow.

       

      Then I ran the flow and it worked as expected.

      Expand Post
  • TimL.58332 (Workflows)

    @HayatoY.21830 (CLARA, Inc.)​  - Some additional context would be helpful.

     

    I am certain this card functions properly I've used it for numbers, text, lists(arrays), and objects successfully. What sort of data are you passing into the Reduce input and what is the expected memo output supposed to be?

     

    I've attached an example parent/helper using reduce that I just made. It just removes vowels from the initial text input. But should give you an idea on usage.

     

     

     

    Expand Post
    • HayatoY.21830 (CLARA, Inc.)

      Thank you for your reply. @TimL.58332 (Workflows)​ 

      I used a list for the return value of the helper flow.

      And I ran the flow and it worked as expected.

This question is closed.
Loading
List-Reduce is errored ... "error": "Duplicate input key: memo"