You need to sign in to do that
Don't have an account?
rajesh k 10
how to get PricebookEntry listprice of each productids in salesforce using map?
Hi,
map<Id,list<PricebookEntry>> ProductidToPricebookEntry = new map<Id,list<PricebookEntry>>();
set<ID> productids=new set<ID>();
for(In_Product__c ip:InProductList)
{
productids.add(ip.Product__c);
if(ProductidToPricebookEntry.containsKey(ip.Product__c))
{
ProductidToPricebookEntry.get(ip.Product__c);
}
}
map<Id,list<PricebookEntry>> ProductidToPricebookEntry = new map<Id,list<PricebookEntry>>();
set<ID> productids=new set<ID>();
for(In_Product__c ip:InProductList)
{
productids.add(ip.Product__c);
if(ProductidToPricebookEntry.containsKey(ip.Product__c))
{
ProductidToPricebookEntry.get(ip.Product__c);
}
}
Try below code to prepare the map
Regards,
Bhanu Mahesh