Duration of the events in the Salesforce calendar can’t go beyond 14 days


I have faced this issue recently in my current project [Later on, I realized that I was aware of this issue earlier perhaps 3 yrs ago when I was working in the consulting firm, my bad memory:)]. The requirement is to create the calendar event when the record is created in one of our Custom object based on the start and end date fields in it.

I created a process builder and it gets triggered when the new record is created in the Custom object. Immediate action in the process builder is to create a record in Event object.

It works fine when the difference in start and end date is less than or equal to 14 days (duration of the event is less than or equal to 14 days) else it throws an error ”

Vote for the below idea so that salesforce removes this limit in the calendar event:


Workaround: I created a flow to create events based on the start and end date. Suppose, start and end date span for 6 months(Start date=15/5/2018 and End date=15/11/2018), split them into 14 days and create events accordingly. So, in this case, I would have created 13 event records approximately from 15/5/2018.

Please comment below for any questions on this.


Tip # 25: Error in creating Lookup relationship


Recently, when I tried creating a lookup relationship with the Product (Standard Object) from the custom object, I got the below error though I was not trying to create the Master Detail relationship:

You cannot create a new Master-Detail relationship on an existing custom object if records already exist. You must first create a Lookup relationship, populate the lookup field with data in all records, and then change the relationship type to Master-Detail.

Moreover, the custom object was a new object and it did not have any records. I was bit confused and the error message is misleading as well. Then, after googling, it looks like you can create a lookup field to Product only if you allow to clear the field if the Product record is deleted(please check the below screenshot for your reference):


Please let me know for any clarification.

Tip # 24: Password issue in ANT

I was using ANT Migration tool to deploy the components(e.g. Layouts, classes etc) from my machine to Sandbox last week. But, for some reason, though I have given the correct user name and password in build.properties file, it was giving me authentication error(Invalid username, password, security token; or user locked out).  I tried the same user name and password to log into Salesforce Sandbox using browser, I could login into it successfully. This looked very strange to me and then I found out the issue:

my password had two $ signs and for some reason, ANT was not able to recognise them. After, I changed the password by excluding the $ signs, it worked.

I thought of sharing this as it would help someone who face this issue since I had to spend about an hour to figure out the issue.


Salesforce Certified Platform Developer I

Recently, I cleared my Salesforce Platform Dev I exam and following are the tips from my side to clear the exam:

  1. If you have access to a Premier Online Training catalogue or Partner Training catalogue, you can go through the Cert Prep video from Salesforce and it will definitely be a very good starting point and will brush up your skills on the topics given in the exam guide . Link for the video – Certification Preparation for Platform Developer I
  2. Go through the questions given in SfdcStudy , Propofs and  Salesforcesteps
  3. Please note that some of the answers for the questions given in the above links might not be correct hence double check by googling or post them in comments section and I will try to answer them.

P.S: I found this link from the net today and I believe that it could be useful too https://quizlet.com/133435950/flashcards

Tip# 23 – Why this error message System.QueryException: Non-selective query against large object type?

Recently, in the project that I am working on, we have received this error in our apex code and this error occurs when querying large objects using SOQL (particularly for queries inside triggers). In our case, SOQL is inside the TriggerHandler which is called by the trigger.

Developers receive this error message when a non-selective query in a trigger executes against an object that contains more than 200,000 records. To avoid this error, ensure that the query is selective.

The performance of a SOQL will depend on the presence of a selective filter(in WHERE Clause). If a SOQL query contains at least 1 selective filter, the query is said to be selective. If the SOQL query doesn’t contain a selective filter, the query is said to be un-selective and will require a full table scan.

How to determine if the query is selective?

  • A query is selective when one of the query filters is on an indexed field and the query filter reduces the resulting number of rows below a system-defined threshold.
  • The selectivity threshold is 10% of the first million records and less than 5% of the records after the first million records, up to a maximum of 333,333 records.


  1. SELECT Id FROM Account WHERE Id IN (<list of account IDs>)

Since the filter is on the ID field which is a standard and Primary Key field, it will have an index created at the DB. If SELECT COUNT() FROM Account WHERE Id IN (<list of account IDs>)returns fewer records than the selectivity threshold, the index on Id is used. This index is typically used when the list of IDs contains only a few records.

2. SELECT Id FROM Account WHERE Name != ”

Since Account is a large object even though Name is indexed (primary key), this filter returns most of the records, making the query non-selective.

3. SELECT Id FROM Account WHERE Name != ” AND CustomField__c = ‘ValueA’
Here we have to see if each filter, when considered individually, is selective. As we saw in the previous example, the first filter isn’t selective. So, let’s focus on the second one. If the count of records returned by SELECT COUNT() FROM Account WHERE CustomField__c = ‘ValueA’ is lower than the selectivity threshold, and CustomField__c is indexed, the query is selective.

For more information:



Also, there are lot of links in stack exchange which discusses this issue and you can refer them as needed: https://salesforce.stackexchange.com/search?q=Non-selective+query



Salesforce Certified Administrator – Summer ’17 Release Exam

1 of 5. Which two features best describe the new Lightning-optimized Log a Call
Choose 2 answers
A. Autolink the Call Log to the Case
B. Autolink the Audit Log to the Case
C. Autopopulate the Case Contact
D. Autopopulate the Case Team

Ans: A & C

2 of 5. How can an administrator allow users to choose different views of a
dashboard in Lightning Experience?
A. Dashboard filters
B. Dashboard designer
C. Report filters
D. Report creator

Ans: A

3 of 5. Where are the files and related records attached when a sales user converts a lead?
A. Contact, account, person account, opportunity records
B. Contact, account, opportunity, quote records
C. Contact, account, opportunity records
D. Contact, account, person account records

Ans: A

4 of 5. What action can be taken in Lightning, if you receive an approval request
that someone else should approve?
A. Delete the associated record
B. Change Approval Entry Criteria
C. Edit Approval Process Manager
D. Re-assign the approval request

Ans: D

5 of 5. Which two Chatter Groups will show a seen-by count of people who viewed the post, in the Lightning Experience?

Choose 2 answers
A. Restricted
B. Private
C. Unlisted
D. Public

Ans: B & C

Salesforce Certified Platform App Builder – Transition Exam

Hi All,

I have cleared my Salesforce Certified Platform App Builder – Transition Exam (SP17) today and here are the tips from my side to clear the exam:

  1. Go through the training resources given in “SECTION 4. RECOMMENDED TRAINING AND REFERENCES” in the exam guide available at https://www.google.com.au/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&cad=rja&uact=8&ved=0ahUKEwjjtYTppPnUAhXFx7wKHdhqCMQQFggoMAA&url=http%3A%2F%2Fcertification.salesforce.com%2FSG_CertifiedPlatformAppBuilderTransition.pdf&usg=AFQjCNGl2oWzGI-d9lbhQZlCfiFBZtmGFw
  2. Go through the questions given in https://www.proprofs.com/quiz-school/story.php?title=transition-app-builder. You may have doubts in answers for some of the questions, you can post them here and I will give my answer accordingly.
  3. Also, go through “Platform App Builder – Full Question Set” as given in http://sfdcstudy.org/platform-app-builder-quizzes/

I got almost 90% of the questions in my exam from the above links, so this would suffice mostly, unless you are not lucky:)

Please let me know for any questions.