• adi salesforce
  • NEWBIE
  • 45 Points
  • Member since 2018

  • Chatter
    Feed
  • 0
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 108
    Questions
  • 74
    Replies
There is a custom field total in account. I want to update field value with the sum of previous record total value and new record total record value if they have same industry and record type
I have a record in account with billing city pune. Now I want to create a record with billing city pune but account information section values should be updated with previous record values whose billing city is pune. how I can achieve it
 
Can anyone explain what approach to use for solving this.
what custom object is required and what fields?

DreamForce is A global consulting agency and proven strategic partner to build mobile solutions. They have a requirement to build a mobile app using SF1 for field service management where the maintenance & repair activity happens at customer’s location. Customer should be able to submit a job request, the form should capture all the required details about a job request. He should be able to log, track & update the job request. The follow up task need to be created for a manager once the job request is submitted. Manager should be able to see a report which will indicate the total revenue generated in a month & a dashboard for the request fixed in a month.
Map<String, map<String, Integer>> ratingVsRecordCountMapOfmap = new Map<String, map<String, Integer>>();
List<Task> lstAggResult = [Select Priority, Status From Task Where Priority != Null AND Status != Null];
if(!lstAggResult.isEmpty()) {
 for(Task objTest : lstAggResult) {
       if(ratingVsRecordCountMapOfmap.containsKey(objTest.Priority)) {
            Map<String, Integer> innermap = ratingVsRecordCountMapOfmap.get(objTest.Priority);
            //if(!innermap.isEmpty()) {
                if(innermap.containsKey(objTest.Status)) {
                   Integer count = innermap.get(objTest.Status) + 1;
                  innermap.put(objTest.Status, count);
               }
               else {
                   innermap.put(objTest.Status, 1);
               }
               ratingVsRecordCountMapOfmap.put(objTest.Priority, innermap);
           //}
        }
       else {
            Map<String, Integer> innermap = new Map<String, Integer>();
            innermap.put(objTest.Status, 1);
            ratingVsRecordCountMapOfmap.put(objTest.Priority, innermap);
       }
    }
}
system.debug('---> ' + ratingVsRecordCountMapOfmap);
                     Hot      cold     warm
Education
energy
banking
-
-
-

Like this I want to display in table
Populate the comma separated related Contact name on Account Description field which should work for insert, update and delete case.