• Eduardo Offermann Palma
  • NEWBIE
  • 0 Points
  • Member since 2015
  • CEO
  • GOCODE Ltda

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 2
    Likes Given
  • 3
    Questions
  • 7
    Replies
Hi,
   I have had searching the way to build with flows an user requirement that is built with the process builder but I have not been able to migrate it. I notice that the difference between scheduled paths (in flows) and scheduled actions (in processes) is that the scheduled actions can be executed, for example, after a series of conditions created on differents decision logic components but in Flows all scheduled paths born from the root. My requirement is:

if conditionA then
      schedule an action 24 hrs after X date to do action Z
else if condictionB then
      schedule an action 48 hrs after Y date to do action W

Instead in Flows I can do this:

schedule an action 24 hrs after X date then
     if conditionA then
          do action Z
schedule an action 48 hrs after Y date then
     if conditionB then
          do action W    

Apparently Flows do not have the possibility to create the "else if" conditions like processes? Could you please help me with that?

Thanks!
We need to provide access to someone can track or monitor the outbound messages that are queued. The problem is the profile user that we need to create apparently should have the "Modify All Data" permission and we need that this user can only track outbound messages and not modify or view data objects. Maybe is there any way to get programatically the outbound messages that are queued in order to create a visualforce page for that?
Hi!,

  I have a huge problem with the Social Media Managed Package becuase it throw the following error when try to save the Conversations.

Update failed. First exception on row 0 with id a08j0000003lXX0AAM; first error: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY, sf4twitter.TwitterConversationTrigger: execution of BeforeUpdate caused by: System.QueryException: Non-selective query against large object type (more than 100000 rows). Consider an indexed filter or contactsalesforce.com about custom indexing. Even if a field is indexed a filter might still not be selective when: 1. The filter value includes null (for instance binding with a list that contains null) 2. Data skew exists whereby the number of matching rows is very large (for instance, filtering for a particular foreign key value that occurs many times) Class.sf4twitter.TwitterPersonAccountManager.getContactFromPersonAccountsByUserName: line 31, column 1 Trigger.sf4twitter.TwitterConversationTrigger: line 148, column 1: []

I suspect that it could be resolved setting an "External Id" on the usernames fields of Contact object.

I opened a case for this but they can not resolve it yet!

Is there a workaround for resolve this?

Thank you!
Hi,
   I have had searching the way to build with flows an user requirement that is built with the process builder but I have not been able to migrate it. I notice that the difference between scheduled paths (in flows) and scheduled actions (in processes) is that the scheduled actions can be executed, for example, after a series of conditions created on differents decision logic components but in Flows all scheduled paths born from the root. My requirement is:

if conditionA then
      schedule an action 24 hrs after X date to do action Z
else if condictionB then
      schedule an action 48 hrs after Y date to do action W

Instead in Flows I can do this:

schedule an action 24 hrs after X date then
     if conditionA then
          do action Z
schedule an action 48 hrs after Y date then
     if conditionB then
          do action W    

Apparently Flows do not have the possibility to create the "else if" conditions like processes? Could you please help me with that?

Thanks!
I need to get the certificate, I am using :

/services/data/v43.0/tooling/sobjects/Certificate/{objectId}/CertificateChain

Using the REST method above, I do get a body nevertheless I am trying to encode it to have exactly the same content when downloading it from the UI. any suggestions will be apreciaate it.
Hi,

I wanted to push External Object with Auth Providers to my scratch org. It's a Files Connect connection to SharePoint Online. The SFDX CLI returns error:
This org does not have the appropriate permissions to use the 'ContentHubSharepointOffice365' data provider
Is it possible for a scratch org to have this sort of permissions? If yes, how can I set them up?

Thanks,
Kamil

I urgently need help with a emailing issue. I want to send an E-mail once some fields in user get changed and everything works fine except that when I want to send the Email to 200 people I am getting the error that I am hitting the limits because it is within a loop. I tried to solve it with an extra class that has all the Message and SingeEmailMessage methods that I need and that implements Queueable. Like that I created a queue that is taking all users that shall get the email. But now I am getting the error: System.LimitException: Too many queueable jobs added to the queue: 51
What I had so far without the extra class:

List<Messaging.SingleEmailMessage > msgList = new List<Messaging.SingleEmailMessage>(); 
        EmailTemplate template = [select Id from EmailTemplate where DeveloperName = : 'My_template']; 
        Messaging.SingleEmailMessage emailMsg; 
        for (User u : [SELECT Id, user_field__c FROM User WHERE Id IN: trigger.new]){ 
             if(u.user_field__c != null){ 
                emailMsg = Messaging.renderStoredEmailTemplate(template.id, u.id, null); // Here appears the error caused by the looping of users
                emailMsg.setSaveAsActivity(false);
                emailMsg.setTreatTargetObjectAsRecipient(false); 
                String[] recipients = new String[]{test@hotmail.com};
                emailMsg.setToAddresses(recipients); 
              } msgList.add(mail); 
        } Messaging.sendEmail(msgList);

Like I said, the alternativ way is to put everything in an separate class that implements Queueable and then call the queue after the IF, like this: System.enqueueJob(new SendingEmail(userLst, template.id, null, false, false)); 

I would prefer to have everything in one class, but how can I avoid hitting the gov.limits when calling Message.renderStoredEmailTemplate(). Any ideas how I can make this solution work? 
Thank you in advance!

Hi,

How to write Test class for ProcessInstanceWorkItem ?
Currently we are firing query to ProcessInstanceWorkItem table to get the workitem Id and updating those records to Approve or Reject as per requirements.
Since we are not able to insert ProcessInstanceWorkItem records Also, In test class, I submiited record for an approval but in next line when I query to ProcessInstanceWorkItem for the same targetObjectId then also I am receiving 0 records.

Please help me in this to resolve this asap.

Thanks

Hi,

 

Does any one know how to get code coverage using ant? I'd like to know exact coverage after successful deployment. Also is there a way to get coverage percentage per class using ant, similar to running test in browser? 

 

Thank you

  • August 13, 2013
  • Like
  • 1

Is there any way to add an error to an record being updated in a trigger and send an email. The trigger needs to send an email (one per batch). The email works fine if the processing generates no errors and I do not use the addError method. If I use the addError method to pass a message back to the user then the email is not sent.

 

So is there a way to send an email and use addError in the same trigger code? If not is there another mechanism that can be used to pass a message back to the user interface (standard salesforce UI).

 

Thanks

 

Dave

  • December 08, 2009
  • Like
  • 0
I need to get the certificate, I am using :

/services/data/v43.0/tooling/sobjects/Certificate/{objectId}/CertificateChain

Using the REST method above, I do get a body nevertheless I am trying to encode it to have exactly the same content when downloading it from the UI. any suggestions will be apreciaate it.

Hi,

 

Does any one know how to get code coverage using ant? I'd like to know exact coverage after successful deployment. Also is there a way to get coverage percentage per class using ant, similar to running test in browser? 

 

Thank you

  • August 13, 2013
  • Like
  • 1