Hi All, I have a CDT(say TestCDT) which has some fields ,for simplici

Hi All,

I have a CDT(say TestCDT) which has some fields ,for simplicity let's take 2 fields. TestCDT.field1 = "a" and TestCDT.field2 = {1,2} (field itself contains and array). I want to copy this content to another CDT (same structure) with values as below
First Occurrence-->TestCDTCopy.field1="a",TestCDTCopy.field2 = 1
Second Occurrence-->TestCDTCopy.field1="a",TestCDTCopy.field2 = 2 (each value in TestCDT.field2 should be split into multiple occurrence,value of all other fields should be same)

Any suggestions please

OriginalPostID-200652

OriginalPostID-200652

  Discussion posts and replies are publicly visible

Parents
  • Following your example:

    load(
              local!TestCDT: type!TestCDT(
                        field1: "a",
                        field2: {1,2}
              ),
              apply(
                        type!TestCDTCopy(
                                  local!TestCDT.field1,
                                  _
                        ),
                        local!TestCDT.field2
              )
    )
Reply
  • Following your example:

    load(
              local!TestCDT: type!TestCDT(
                        field1: "a",
                        field2: {1,2}
              ),
              apply(
                        type!TestCDTCopy(
                                  local!TestCDT.field1,
                                  _
                        ),
                        local!TestCDT.field2
              )
    )
Children
No Data