I have some nested CDTs, like a nested in b, b nested in c, I want to cast it to recordtype with relationship, like C has one-to-many relationship to B, B has one-to-many relationship to A. All fields are mapped, how can I cast?
Discussion posts and replies are publicly visible
Assuming you have the same names for your fields, then you just cast it and it should work - here's an example:
If you don't have the same field names, then you may need to do some massaging of the data to get it in the right format like others have mentioned.