You need to sign in to do that
Don't have an account?
Ron08
nested maps
Can someone please help with populating nested maps:
I have 2 maps:
map<id, map<id, string>> map1 = new map<id, map<id, string>>();
map<id, map<id, string>> map2 = new map<id, map<id, string>>();
lets say map1 contains values:
outterid1, innerid1, String1
outterid1, innerid1, String2
outterid1, innerid2, String1
outterid2, innerid1, String1
I need populate map2 using values from map1 as below
outterid1, innerid1, String1;String2
outterid1, innerid2, String1
outterid2, innerid1, String1
Thanks.
I have 2 maps:
map<id, map<id, string>> map1 = new map<id, map<id, string>>();
map<id, map<id, string>> map2 = new map<id, map<id, string>>();
lets say map1 contains values:
outterid1, innerid1, String1
outterid1, innerid1, String2
outterid1, innerid2, String1
outterid2, innerid1, String1
I need populate map2 using values from map1 as below
outterid1, innerid1, String1;String2
outterid1, innerid2, String1
outterid2, innerid1, String1
Thanks.
here is some idea about add values in nested map.
hope this will give some idea.
Thanks
karthik
You can reference from below link on how to populate nested map :
https://developer.salesforce.com/forums/?id=906F000000092uHIAQ
https://www.reddit.com/r/salesforce/comments/6hplul/how_to_populate_data_in_a_3rdlevel_deep_nested_map/
I hope you find the above solution helpful. If it does, please mark as Best Answer to help others too.
Thanks and Regards,
Ajay Dubedi
www.ajaydubedi.com
Here is a simple process to create nested Map.
I hope you find the above solution helpful. If it does, please mark as Best Answer to help others too.
Thanks and Regards,
Deepali Kulshrestha
www.kdeepali.com