Data Skew Salesforce

Data Skew Salesforce

What is data skew in Salesforce?

Data skew in Salesforce happens when large number of child records (more then 10k) are linked to one parent records.

Data Skew Salesforce

Type of Data skew

There are 3 types of data skew in salesforce:

  • Account data skew
  • Ownership skew
  • Lookup Skew

Account data skew:

Certain Salesforce objects, like accounts and opportunities, have special data relationships that maintain parent and child record access under private sharing models. Too many child records associated with the same parent object in one of these relationships causes account data skew. Say you have a bunch of unassigned contacts and park them under one account named “Unassigned.” This can create issues with record locking and sharing performance.

Certain Salesforce objects, such as accounts and opportunities, have special data relationships that maintain parent and child record access under private sharing models. If too many child records are associated with same parent object in one of these relationships, this imbalance causes something called “account data skew,” which in turn causes performance problems.

If you are unfamiliar with account data skew, you can read more about it here.

Ownership Skew:

Similarly, when a large number of records with the same object type are owned by a single user, this imbalance causes something called “ownership skew.” Ownership skew also causes performance problems, which can surface when you’re managing your role hierarchy and sharing rules.

If you are unfamiliar with ownership skew, you can read more about it here.

Lookup Skew:

Lookup skew happens when a very large number of records are associated to a single record in the lookup object.  Because you can place lookup fields on any object in Salesforce, lookup skew can create problems for any object within your organization.

For more details about data skew refer to official salesforce link.

Permanent link to this article: http://www.sfdcpoint.com/salesforce/data-skew-salesforce/

Salesforce developer interview questions

Salesforce developer interview questions

Salesforce developer interview questions and answers

Here is list of  all Salesforce developer interview questions

  • What is Salesforce?
  • What is Cloud computing?
  • What is CRM?
  • What is PaaS?
  • What is SaaS?
  • What is IaaS?
  • What are different Salesforce Editions?
  • What is Master-detail  relationship?
  • What is Many-to-many relationship?
  • What is Organization-wide defaults?
  • What is role hierarchy?
  • What are the difference between a Role and Profile?
  • What are Sharing Rules?
  • What is Manual sharing?
  • What is Profile?
  • What is Apex?
  • What is a Trigger?
  • What are the various event on which a trigger can fire?
  • What are different type of Triggers?
  • What are the considerations while implementing the Triggers?
  • What is Salesforce Lightning?
  • What are the different Lightning component bundles?
  • What is Lightning Experience?
  • What is Lightning Design System?
  • What happens to my existing Visualforce Pages?
  • What are the type of events into Salesforce Lightning component?
  • What is the basic difference between Application Event and Component Event?
  • Component events vs Application events. Which one I should use?
  • Can we Include One Lightning component to another ?
  • How can we use Lightning Components with the Salesforce1 Mobile App ?
  • How can we use a lightning component in a VisualForce Page?
  • Can we integrate Lightning components with another framework like Angular?
  • Can we include external JavaScript/CSS libraries like jQuery, bootstrap in components?
  • How to ensure FLS while working with Lightning Component?
  • How can we display loading spinner in lightning component?
  • How can we conditionally display content in lightning component?
  • What is the use of force:hasRecordId interface?
  • How to get current record id in lightning component?
  • What is a FlexiPage in lightning?
  • How can we deploy lightning components?
  • What Is Lightning Data Service?
  • What are List of Global value providers in lightning?
  • How to create popup in lightning component?

 

Here is list of all Salesforce developer interview questions and answers

What is Salesforce?

Salesforce is the world’s #1 customer relationship management (CRM) platform. Salesforce provides cloud-based, CRM applications for sales, service, marketing, and more.

Salesforce has essentially changed how enterprise software is delivered and used. Its software is cloud-based and hence doesn’t need IT experts to set up anything. Salesforce has defined the ideal way as how to connect with customers. Building meaningful and lasting bond with the customers, identifying their needs, address problems faster and deploy apps that are customer focused is all possible through Salesforce.

Salesforce Technologies is one of the leading and very hot Technology in IT industry. Through Salesforce.com Technology thousands of Job opportunity are created for Salesforce developers and Salesforce Administration Job Seekers. As per Forbes magazine, nearly 55% of enterprises predict cloud computing will enable new business model in three years. So Salesforce is one of the Cloud Computing Technology which have bright future in the upcoming years. Salesforce provides different enterprise cloud computing applications to all size industries and businesses.

Salesforce applications are provided on subscription basis primarily through direct sales effort and indirectly through partners.

What is Cloud computing?

Cloud computing is a kind of outsourcing of computer programs. Using cloud computing, users are able to access software and applications from wherever they are; the computer programs are being hosted by an outside party and reside in the cloud. This means that users do not have to worry about things such as storage and power, they can simply enjoy the end result.

Cloud computing is shared pools of configurable computer system resources and higher-level services that can be rapidly provisioned with minimal management effort, often over the Internet. Cloud computing relies on sharing of resources to achieve coherence and economies of scale, similar to a public utility.

What is CRM?

CRM means “Customer Relationship Management “. We can understand from the full form where CRM is an application used to automate Sales and marketing functions by a using a Software called CRM Software. By using CRM Software every Company / Organization plans to increase their revenues and profits. This strategy of increasing revenue is done mainly by attracting Customers, clients, Sales etc.

What is PaaS?

Platform as a Service (PaaS)

The branch of cloud computing that allows users to develop, run, and manage applications without having to get caught up in code, storage, infrastructure and so on.

There are several types of PaaS. Every PaaS option is either public, private, or a hybrid mix of the two. Public PaaS is hosted in the cloud, and its infrastructure is managed by the provider. Private PaaS, on the other hand, is housed in onsite servers or private networks and is maintained by the user. Hybrid PaaS uses elements from both public and private and is capable of executing applications from multiple cloud infrastructures.

What is SaaS?

Software as a Service (SaaS)

Using the cloud, software such as an internet browser or application is able to become a usable tool.

What is IaaS?

Infrastructure as a Service (IaaS)

A third party hosts elements of infrastructure, such as hardware, software, servers, and storage, also providing backup, security, and maintenance.

What are different Salesforce Editions?

  • Essentials: Designed for small businesses that want to get started with a CRM system quickly. It includes intuitive walkthroughs and a setup assistant to get started, an easy-to-use UI, and administration tools to customize your deployment as you grow.
  • Professional: Designed for businesses requiring full-featured CRM functionality. It includes straightforward and easy-to-use customization, integration, and administration tools to facilitate any small to midsize deployment.
  • Enterprise: Meets the needs of large and complex businesses. It gives you advanced customization and administration tools, in addition to all the functionality available in Professional Edition, that can support large-scale deployments. Enterprise Edition also includes access to Salesforce APIs, so you can easily integrate with back-office systems.
  • Unlimited: Maximizes your success and extends it across the entire enterprise through the Lightning Platform. It gives you new levels of platform flexibility for managing and sharing all your information on demand. Includes all Enterprise Edition functionality, Premier Support, full mobile access, unlimited custom apps, increased storage limits, and other features.
  • Developer: Provides access to the Lightning Platform and APIs. It lets developers extend Salesforce, integrate with other applications, and develop new tools and applications. Developer Edition also provides access to many of the features available in Enterprise Edition.

 

What is Master-detail  relationship?

Master-detail closely links objects together such that the master record controls certain behaviors of the detail and subdetail record. For example, you can define a two-object master-detail relationship, such as Account—Expense Report, that extends the relationship to subdetail records, such as Account—Expense Report—Expense Line Item. You can then perform operations across the master—detail—subdetail relationship.

What is Many-to-many relationship?

Many-to-many You can use master-detail relationships to model many-to-many relationships between any two objects. A many-to-many relationship allows each record of one object to be linked to multiple records from another object and vice versa. For example, you create a custom object called “Bug” that relates to the standard case object such that a bug could be related to multiple cases and a case could also be related to multiple bugs.

Lookup Links two objects together. Lookup relationships are similar to master-detail relationships, except they do not support sharing or roll-up summary fields. With a lookup relationship, you can:

  • Link two different objects.
  • Link an object with itself (with the exception of the user object; see Hierarchical). For example, you might want to link a custom object called “Bug” with itself to show how two different bugs are related to the same problem.

 

What is Organization-wide defaults?

Organization Wide Defaults(OWD) in salesforce is the baseline level of access that the most restricted user should have. Organizational Wide Defaults are used to restrict access. You grant access through other means like(sharing rules, Role Hierarchy, Sales Teams and Account teams, manual sharing, Apex Sharing ). In simple words Organization Wide Defaults(OWD) specify the default level of access users have to each other’s records.

For more details please level to below post Organization Wide Defaults(OWD) in salesforce

What is role hierarchy?

It give access for users higher in the hierarchy to all records owned by users below them in the hierarchy. Role hierarchies don’t have to match your organization chart exactly. Instead, each role in the hierarchy should represent a level of data access that a user or group of users needs.

What are the difference between a Role and Profile?

Roles are one of the ways you can control access to records. They also impact reports (e.g. “My Teams” filter). Roles come into play if your security model (OWDs) are set to private.

Profiles help determine record privileges. Assuming the User can see the record, Profiles determine what the User can do, view or edit on that record. Profiles control other system privileges as well (mass email, export data, etc)

In simple words, Roles are one of the ways you can control access to records and Profiles determine what the User can do, view or edit on that record.

What are Sharing Rules?

Sharing Rules are automatic exceptions to organization-wide defaults for particular groups of users, so they can get to records they don’t own or can’t normally see. Sharing rules, like role hierarchies, are only used to give additional users access to records. They can’t be stricter than your organization-wide default settings.

What is Manual sharing?

It allows owners of particular records to share them with other users. Although manual sharing isn’t automated like org-wide sharing settings, role hierarchies, or sharing rules, it can be useful in some situations, such as when a recruiter going on vacation needs to temporarily assign ownership of a job application to someone else.

What is Profile?

Each user has a single profile that controls which data and features that user has access to. A profile is a collection of settings and permissions. Profile settings determine which data the user can see, and permissions determine what the user can do with that data.
  • The settings in a user’s profile determine whether she can see a particular app, tab, field, or record type.
  • The permissions in a user’s profile determine whether she can create or edit records of a given type, run reports, and customize the app.

Profiles usually match up with a user’s job function (for example, system administrator, recruiter, or hiring manager), but you can have profiles for anything that makes sense for your Salesforce org. A profile can be assigned to many users, but a user can have only one profile at a time.

What is Apex?

Apex is a strongly typed, object-oriented programming language that allows developers to extend the Salesforce platform by writing their own business logic into the platform. Apex looks similar to Java and can be launched through a variety of user-initiated events such as record updates, button clicks, triggers on objects, or external web service requests.

What is a Trigger?

Apex triggers enable you to perform custom actions before or after events to records in Salesforce, such as insertions, updates, or deletions. Just like database systems support triggers, Apex provides trigger support for managing records.

Use triggers to perform tasks that can’t be done by using the point-and-click tools in the Salesforce user interface. For example, if validating a field value or updating a field on a record, use validation rules and workflow rules instead.

What is Trigger Syntax?

trigger TriggerName on ObjectName (trigger_events) {
   code_block
}

What are the various event on which a trigger can fire?

A trigger is a set of statement which can be executed on the following events. In above trigger events one or more of below events can be used with comma separated.

  • before insert
  • before update
  • before delete
  • after insert
  • after update
  • after delete
  • after undelete

What are different type of Triggers?

There are two types of triggers:

  • Before triggers are used to perform a task before a record is inserted or updated or deleted. These are used to update or validate record values before they are saved to the database.
  • After triggers are used if we want to use the information set by Salesforce system and to make changes in the other records. are used to access field values that are set by the system (such as a record’s Id or LastModifiedDate field), and to affect changes in other records. The records that fire the after trigger are read-only.

What are the considerations while implementing the Triggers?

Consider the following before implementing the triggers.

  • Upsert trigger fires on 4 different events :- before(insert, update), after (insert, update)
  • Merge trigger are fired on both events on delete
  • Field history is updated after the trigger has successfully finished processing data.
  • Any callout should be asynchronous so that trigger does not have to wait for the response.
  • A trigger cannot have a static keyword in its code.
  • If a trigger completes successfully the changes are committed to the database and if it fails the transaction is rolled back.

Read the Apex Developer Guide for more detailed considerations.

For more details about triggers in salsforce refer to below links

Salesforce Interview Questions on Triggers

Triggers in Salesforce

What is Salesforce Lightning?

Lightning is the collection of tools and technologies behind a significant upgrade to the Salesforce platform. Lightning includes:

  • Experience: A set of modern user interfaces optimized for speed. This includes the Lightning Experience, Salesforce1 Mobile app and template-based communities.
  • Lightning Component Framework: A JavaScript framework and set of standard components that allow you to build reusable components to customize the Lightning Experience, Salesforce1 Mobile app and template-based communities and build your own standalone apps.
  • Visual Building Tools: Drag-and-drop technologies for fast and easy app building & customizations. Use the Lightning App Builder to customize the Lightning Experience and Salesforce1 Mobile app. Use the Community Builder to customize template-based communities.
  • Lightning Exchange: A section of the AppExchange where you can find 70+ partner components to jumpstart your development.
  • Lightning Design System: Style guides and modern enterprise UX best practices to build pixel perfect apps that match the look and feel of the Lightning Experience and Salesforce1 Mobile app.

 

What are the different Lightning component bundles?

  • Component :UI for lightning component
  • Controller: Contains client-side controller methods to handle events in the component.
  • Helper: JavaScript functions that can be called from any JavaScript code in a component’s bundle
  • Style: Contains styles for the component.
  • Document: A description, sample code, and one or multiple references to example components
  • Design: File required for components used in Lightning App Builder, Lightning pages, or Community Builder.
  • SVG: Custom icon resource for components used in the Lightning App Builder or Community Builder.
  • Renderer: Client-side renderer to override default rendering for a component.

Click Here for official Salesforce documentation.

What is Lightning Experience?

Lightning Experience is the name for the all new Salesforce desktop app, with new features, built with a modern user interface and optimized for speed.

What is Lightning Design System?

Style guides and modern enterprise UX best practices to build pixel perfect apps that match the look and feel of the Lightning Experience and Salesforce1 Mobile app. Click Here for official link.

What happens to my existing Visualforce Pages?

They’ll continue to be supported in the current UI and Lightning Experience. See the Trailhead module on this topic.

What are the type of events into Salesforce Lightning component?

  • Application Event – Scope of this event is throughout the lightning App and any component which has registered for this event would get a notification.
  • Component Event– Scope of this event is within itself or the parent component of this event, all the components declared within the parent component would get notified of this event.
  • System Event- these are the events fired by Salesforce’s system during the lifecycle of the lightning app.

 

What is the basic difference between Application Event and Component Event?

Component events are used to do communication between child and parent. They use bubbling and capture same as used in DOM events. A change in a child component can be communicated to the parent component via component event.

Application events are used to communicate any change in the component to a broader audience. Any component who has registered for this event will get a notified.

Component events vs Application events. Which one I should use?

Component events can only be handled by components above them in the containment hierarchy, therefore, their usage is localized to the components that need to know about them.

Application events are best used for something that should be handled at the application level, such as navigating to a specific record. Application events allow communication between components that are in separate parts of the application and have no direct containment relationship.

 

Can we Include One Lightning component to another ?

Yes we can include one Lightning component inside another Lightning component

How can we use Lightning Components with the Salesforce1 Mobile App ?

We can create a custom Lightning tab that points to our component and include that tab in our Salesforce1 Mobile navigation.

How can we use a lightning component in a VisualForce Page?

A Lightning component can be embed in any webpage using a very powerful and flexible feature, Lighting out. When used with Visualforce some complexity becomes simpler.
Lightning component can be added to Visualforce page in three steps:

  1. We have to first Add the Lightning Components for Visualforce JavaScript library to your targetted Visualforce page using the tag.
  2. Next we have to create and refer a Lightning app which is used to the component dependencies.
  3. Lastly we need to write a JavaScript function which will finally create the the component on the page using $Lightning.createComponent()

For more details, please refer Use Lightning Components in Visualforce Pages

Can we integrate Lightning components with another framework like Angular?

Yes, we can integrate lightning with any 3rd party framework.

Can we include external JavaScript/CSS libraries like jQuery, bootstrap in components?

Yes, we can use multiple libraries in our lightning component like JQuery, Bootstrap, custom CSS and custom Javascript libraries using static resource.

What is use of aura:method tag in salesforce lightning?

We can use <aura:method> to define a method as part of a component’s API. This enables you to directly call a method in a component’s client-side controller instead of firing and handling a component event. Using <aura:method> simplifies the code needed for a parent component to call a method on a child component that it contains.

How to ensure FLS while working with Lightning Component?

FLS and CRUD are not automatically enforced in the lightning component whenever any object is referenced in the Apex Controller and the component will display the fields and records for which the users do not have access. Therefore we should manually enforce the FLS and CRUD in the Apex Controller. Also when we use Lightning Data service  it takes care of FLS and CRUD for us.

How can we display loading spinner in lightning component?

Spinners are CSS loading indicators that should be shown when retrieving data or performing slow computations. lightning:spinner displays an animated spinner image to indicate that a request is loading. This component can be used when retrieving data or performing an operation that takes time to complete.

aura:waiting and aura:donewaiting can be used for controlling the loading spinner.

For more details please refer to below post lightning spinner

How can we conditionally display content in lightning component?

We can use aura:if to conditionally display content in lightning component. For more details refer to below post aura:if in lightning component

What is the use of force:hasRecordId interface?

or

How to get current record id in lightning component?

Add the force:hasRecordId interface to a Lightning component to enable the component to be assigned the ID of the current record. The current record ID is useful if the component is used on a Lightning record page, as an object-specific custom action or action override in Lightning Experience or the Salesforce app, and so on. This interface has no effect except when used within Lightning Experience, the Salesforce mobile app, and template-based communities.

For more details refer below link force:hasRecordId

What is a FlexiPage in lightning?

FlexiPage represents the metadata associated with a Lightning page. A Lightning page represents a customizable screen made up of regions containing Lightning components.
A Lightning page can contain upto 25 components. Flexi page are stored as xml file and can be deployed using metadata api or any deployment tool.

Lightning pages are referred as FlexiPages in API and referred as Lightning pages elsewhere in SFDC documentation.

How can we deploy lightning components?

Lightning components can be deployed similar to any other component using changeset, ant migration tool, eclipse or any other migration tool.

What Is Lightning Data Service?

Use Lightning Data Service to load, create, edit, or delete a record in your component without requiring Apex code. Lightning Data Service handles sharing rules and field-level security for you. In addition to not needing Apex, Lightning Data Service improves performance and user interface consistency. Main advantage of using lightning data service is that we can perform basic operations without Apex code.

For more details refer to below link Lightning Data Service

What are List of Global value providers in lightning?

  • $globalID
  • $Browser
  • $Label
  • $Locale
  • $Resource

 

How to create popup in lightning component?

Modals/Popup Box are used to display content in a layer above the app. This paradigm is used in cases such as the creation or editing of a record, as well as various types of messaging and wizards.

For more details, refer to below link Modal/Popup Lightning Component Salesforce

For more details about lightning, refer to Salesforce Lightning Interview Questions

For more salesforce developer interview questions refer to below links

Salesforce Lightning Interview Questions

Salesforce admin interview questions

Salesforce interview questions

Good luck for interview 🙂

Permanent link to this article: http://www.sfdcpoint.com/salesforce/salesforce-developer-interview-questions/

Salesforce Chrome Extensions

Top Chrome Extensions for Salesforce

Salesforce Chrome Extensions are made for salesforce developers and end-users to ease their daily life in the Salesforce world. I am a big fan of Salesforce Chrome Extensions being an end-user as well as developers. It has helped me work better and faster. Here are my Favourite extensions :

Salesforce Chrome Extension

Salesforce Inspector

Offered by: Søren Krabbe

As part of the salesforce admin family for many years, I feel the need of such chrome extensions. It really helps to see all the data without adding fields to the layout, make a quick export/import of data from excel/CSV or via query and much more functionality. Explore the Chrome extensions to know more about it.

Salesforce Navigator

Offered by:  Daniel Nakov

Navigating in and around Salesforce is not too easy. This extension helps you get to any salesforce page quickly. Just type in what you need to do.

Salesforce Inspector for Lightning

Offered by:  Salesforce

The Salesforce Lightning Inspector opens up and improves your Lightning Component development, giving you access to a wealth of data about your running applications and components.

Record and Metadata Comparator 

Offered by:  Rajiv Bhatt

Compare Record data values and object metadata in Salesforce
Compare Object Metadata and it’s record values in Salesforce (now supports Lightning!) and see all differences in just four clicks!

Salesforce Advanced Code Search

Offered by: Sameernmiraj

By using the advanced quick find you can get your code a few clicks shorter. Also, you can search any string of your code. Using this extension you can search your code components your salesforce instance Apex Classes, Apex Triggers , Visualforce Pages , Visualforce Components, Lighting Component.   It works on Salesforce Lightning.

Salesforce Enhanced Code Searcher

Offered by: Shubham Bhatt

It is similar to the Salesforce Advanced Code Search but Enhanced it for custom settings’ field search and tooltip in the searched results
By using the advanced quick find you can get your code a few clicks shorter. Also, you can search any string your code

Salesforce Admin Check All

Offered by:  Dan Pazehoski

I can understand how tiring it becomes to manually check each box when you would like to give edit permissions for all fields in an object. This extension makes the profile setup faster.Salesforce Admin Check All is an extension that enhances the Salesforce Setup pages by adding “check all” checkboxes to various checkbox lists. This enhanced functionality helps make some setup tasks more efficient by potentially saving administrators from having to manually check each checkbox in a list individually.

Salesforce.com Enhanced Formula Editor

Offered by:  Kyle Peterson

Enhances the formula editor textareas to have syntax highlighting, tabbing, parenthesis matching, and find and replace.
Use this extension to save time and headaches working with formulas. It helps you more quickly understand the structure of a formula, review the fields used by it, and edit the formula.

When you visit a formula edit page it will automatically enhance the formula textarea with a code editor. This includes formula fields, validation rule formulas, workflow rule formulas, and field update formulas.

SOQL Extractor and Analyzer for SalesForce

Offered by: Rajiv Bhatt

Extract SOQL queries with their execution counts from Debug Logs of Salesforce. Helps you analyze the ‘Too Many SOQLs’ error.

For ex: If you have got queries that hit the Account object 5 times, you might want to have a relook at the code and optimize the code in a way that you get all the data from the Account object in single SOQL query (instead of querying it 5 times).

Salesforce Logins by Synebo

Offered by: Synebo

Best in class solution to manage your Salesforce credentials. Thanks to this extension’s security token support, you can escape those pesky verification codes and quickly sign on with one-click login. You can also import and export credentials by copying login information to a clipboard or generating a session login link. Stored data is synced to Chrome automatically, and passwords/tokens are protected by encryption, making this a secure option for managing multiple accounts.

Custom Settings Exporter for Salesforce

Offered by:  Rajiv Bhatt

Export all Custom Settings from Salesforce To Excel in three clicks
Export all Salesforce Custom Settings to Excel in 3 clicks!

Use this extension to export all the custom settings from your org to an excel.

Profile Comparator for Salesforce

Offered by: by Rajiv Bhatt

Compare Salesforce user-profiles and see all differences in just four clicks!
This extension can compare any two salesforce profiles (could be from the same org or different orgs) and highlights all the differences.

Lightning Extension

Offered by: by Salesforce

Enhance productivity with new add-on features
Lightning Extension is a library of features created by the Lightning Product Management team at Salesforce. This extension is designed to complement the user experience with continuous productivity feature releases. These features provide end-users with rich enhancements that aren’t available out-of-the-box with Lightning, like Dark Mode.

I personally want to thank all Salesforce Chrome Extensions Developer who have made our day to day salesforce life easier.

Did you find this useful? Please let us know if you come around useful chrome extensions and I am happy to add them to the list. I hope this will help you to work better and faster 🙂

 

Permanent link to this article: http://www.sfdcpoint.com/salesforce/salesforce-chrome-extensions/

Batch Apex Example In Salesforce

Batch Apex Example In Salesforce

Batch Apex Example In Salesforce

What is Batch Apex in Salesforce?

Batch Apex is used to run large jobs (think thousands or millions of records!) that would exceed normal processing limits. Using Batch Apex, you can process records asynchronously in batches (hence the name, “Batch Apex”) to stay within platform limits. If you have a lot of records to process, for example, data cleansing or archiving, Batch Apex is probably your best solution.

Here’s how Batch Apex works under the hood. Let’s say you want to process 1 million records using Batch Apex. The execution logic of the batch class is called once for each batch of records you are processing. Each time you invoke a batch class, the job is placed on the Apex job queue and is executed as a discrete transaction.

Advantage of using batch Apex

  • Every transaction starts with a new set of governor limits, making it easier to ensure that your code stays within the governor execution limits.
  • If one batch fails to process successfully, all other successful batch transactions aren’t rolled back

 

Batch Apex Syntax

To write a Batch Apex class, your class must implement the Database.Batchable interface and include the following three methods:

start
Start method is automatically called at the beginning of the apex job. This method will collect record or objects on which the operation should be performed. These records are divided into subtasks and pass those to execute method.

Used to collect the records or objects to be passed to the interface method execute for processing. This method is called once at the beginning of a Batch Apex job and returns either a Database.QueryLocator object or an Iterable that contains the records or objects passed to the job.

Most of the time a QueryLocator does the trick with a simple SOQL query to generate the scope of objects in the batch job. But if you need to do something crazy like loop through the results of an API call or pre-process records before being passed to the execute method, you might want to check out the Custom Iterators link in the Resources section.

With the QueryLocator object, the governor limit for the total number of records retrieved by SOQL queries is bypassed and you can query up to 50 million records. However, with an Iterable, the governor limit for the total number of records retrieved by SOQL queries is still enforced.

execute
Execute Method performs an operation which we want to perform on the records fetched from start method.

Performs the actual processing for each chunk or “batch” of data passed to the method. The default batch size is 200 records. Batches of records are not guaranteed to execute in the order they are received from the start method.

This method takes the following:

  • A reference to the Database.BatchableContext object.
  • A list of sObjects, such as List<sObject>, or a list of parameterized types. If you are using a Database.QueryLocator, use the returned list.
finish

Finish method executes after all batches are processed. Use this method to send confirmation email notifications

Used to execute post-processing operations (for example, sending an email) and is called once after all batches are processed.

Here’s what the skeleton of a Batch Apex class looks like:

global class MyBatchClass implements Database.Batchable<sObject> {
    global (Database.QueryLocator | Iterable<sObject>) start(Database.BatchableContext bc) {
        // collect the batches of records or objects to be passed to execute
    }
    global void execute(Database.BatchableContext bc, List<P> records){
        // process each batch of records
    }    
    global void finish(Database.BatchableContext bc){
        // execute any post-processing operations
    }    
}

Key points about batch Apex

  • To use batch Apex, write an Apex class that implements Database.Batchable interface and make your class global
  • Implement the following 3 methods
      • start()
      • execute()
      • finish()
  • The default batch size is 200

 

Monitoring Batch Apex

To monitor or stop the execution of the batch Apex job, from Setup, enter Apex Jobs in the Quick Find box, then select Apex Jobs.

Batch Apex Example

global class BatchApexExample implements Database.Batchable<sObject> {
    global Database.QueryLocator start(Database.BatchableContext BC) {
        // collect the batches of records or objects to be passed to execute
        
        String query = 'SELECT Id, Name FROM Account';
        return Database.getQueryLocator(query);
    }
    
    global void execute(Database.BatchableContext BC, List<Account> accList) {
       
        // process each batch of records default size is 200
        for(Account acc : accList) {        
           	// Update the Account Name 
            acc.Name = acc.Name + 'sfdcpoint';
        }
        try {
        	// Update the Account Record
            update accList;
        
        } catch(Exception e) {
            System.debug(e);
        }
        
    }   
    
    global void finish(Database.BatchableContext BC) {
    	// execute any post-processing operations like sending email
    }
}

Invoking a Batch Class

To invoke a batch class, simply instantiate it and then call Database.executeBatch with the instance:

MyBatchClass myBatchObject = new MyBatchClass(); 
Id batchId = Database.executeBatch(myBatchObject);

You can also optionally pass a second scope parameter to specify the number of records that should be passed into the execute method for each batch. Pro tip: you might want to limit this batch size if you are running into governor limits.

Id batchId = Database.executeBatch(myBatchObject, 100);

Each batch Apex invocation creates an AsyncApexJob record so that you can track the job’s progress. You can view the progress via SOQL or manage your job in the Apex Job Queue. We’ll talk about the Job Queue shortly.

AsyncApexJob job = [SELECT Id, Status, JobItemsProcessed, TotalJobItems, NumberOfErrors FROM AsyncApexJob WHERE ID = :batchId ];

 

Scheduling Batch Apex

can also use the Schedulable interface with batch Apex classes. The following example implements the Schedulable interface for a batch Apex class called batchable:

global class scheduledBatchable implements Schedulable {
   global void execute(SchedulableContext sc) {
      BatchApexExample b = new BatchApexExample(); 
      Database.executeBatch(b);
   }
}

 

Test class for batch Apex

@isTest
private class BatchApexExampleTest {
    static testmethod void test() {
        // Create test accounts to be updated by batch
	Account[] accList = new List();
	for (Integer i=0;i<400;i++) {
	    Account ac = new Account(Name = 'Account ' + i);
	    accList.add(ac);
	}
	insert accList;

        Test.startTest();
            BatchApexExample b = new BatchApexExample();
	    Database.executeBatch(b);
        Test.stopTest();
        // Verify accounts updated
	Account[] accUpdatedList = [SELECT Id, Name FROM Account];
	System.assert(accUpdatedList[0].Name.Contains('sfdcpoint'));
    }
}

Best Practices for batch Apex

As with future methods, there are a few things you want to keep in mind when using Batch Apex. To ensure fast execution of batch jobs, minimize Web service callout times and tune queries used in your batch Apex code. The longer the batch job executes, the more likely other queued jobs are delayed when many jobs are in the queue. Best practices include:

  • Only use Batch Apex if you have more than one batch of records. If you don’t have enough records to run more than one batch, you are probably better off using Queueable Apex.
  • Tune any SOQL query to gather the records to execute as quickly as possible.
  • Minimize the number of asynchronous requests created to minimize the chance of delays.
  • Use extreme care if you are planning to invoke a batch job from a trigger. You must be able to guarantee that the trigger won’t add more batch jobs than the limit.

 

For more details about batch apex refer to batch apex trailhead

Permanent link to this article: http://www.sfdcpoint.com/salesforce/batch-apex-example-in-salesforce/

What is an API

What is an API? (Application Programming Interface)

An application programming interface (API) is an interface or communication protocol between different parts of a computer program intended to simplify the implementation and maintenance of software.

API is an acronym, and it stands for “Application Programming Interface”, API allows two applications to talk to each other.

An API may be for a web-based system, operating system, database system, computer hardware, or software library.

APIs by use cases

APIs can be classified according to the systems for which they are designed.

Database APIs. Database APIs enable communication between an application and a database management system. Developers work with databases by writing queries to access data, change tables, etc. The Drupal 7 Database API, for example, allows users to write unified queries for different databases, both proprietary and open source (Oracle, MongoDB, PostgreSQL, MySQL, CouchDB, and MSSQL).

Another example is ORDS database API, which is embedded into Oracle REST Data Services.

Operating systems APIs. This group of APIs defines how applications use the resources and services of operating systems. Every OS has its set of APIs, for instance, Windows API or Linux API (kernel–user space API and kernel internal API).

Apple provides API reference for macOS and iOS in its developer documentation. APIs for building applications for Apple’s macOS desktop operating system are included in the Cocoa set of developer tools. Those building apps for the iOS mobile operating system use Cocoa Touch – a modified version of Cocoa.

Remote APIs. Remote APIs define standards of interaction for applications running on different machines. In other words, one software product accesses resources located outside the device that requests them, which explains the name. Since two remotely located applications are connected over a communications network, particularly the internet, most remote APIs are written based on web standards. Java Database Connectivity API and Java Remote Method Invocation API are two examples of remote application programming interfaces.

Web APIs. This API class is the most common. Web APIs provide machine-readable data and functionality transfer between web-based systems which represent client-server architecture. These APIs mainly deliver requests from web applications and responses from servers using Hypertext Transfer Protocol (HTTP).

Developers can use web APIs to extend the functionality of their apps or sites. For instance, the Pinterest API comes with tools for adding users’ Pinterest data like boards or Pins to a website. Google Maps API enables the addition of a map with an organization’s location.

In today’s modern era, Web API is most popular API. Web API is used in our day to day use of mobile phone, laptop and other smart devices.

A Web API is an application programming interface for either a web server or a web browser. It is a web development concept, usually limited to a web application’s client-side (including any web frameworks being used)

API Release policies

APIs are one of the more common ways technology companies integrate with each other. Those that provide and use APIs are considered as being members of a business ecosystem.

The main policies for releasing an API are:

  • Private: The API is for internal company use only.
  • Partner: Only specific business partners can use the API. For example, transportation network companies such as Uber and Lyft allow approved third-party developers to directly order rides from within their apps. This allows the companies to exercise quality control by curating which apps have access to the API, and provides them with an additional revenue stream.[31]
  • Public: The API is available for use by the public. For example, Microsoft makes the Microsoft Windows API public, and Apple releases its APIs Carbon and Cocoa, so that software can be written for their platforms.

Example of an API

Most common example of using API is using google map. When we are using google map, we perform different type of requests like finding route between two points. Apps like Uber also use google API in background in their app.

REST API(Representational state transfer)

Representational state transfer (REST) is a software architectural style that defines a set of constraints to be used for creating Web services. Web services that conform to the REST architectural style, called RESTful Web services, provide interoperability between computer systems on the Internet. RESTful Web services allow the requesting systems to access and manipulate textual representations of Web resources by using a uniform and predefined set of stateless operations. Other kinds of Web services, such as SOAP Web services, expose their own arbitrary sets of operations.

REST API provides a powerful, convenient, and simple REST-based web services interface for interacting with Salesforce. Its advantages include ease of integration and development, and it’s an excellent choice of technology for use with mobile applications and web projects. For certain projects, you may want to use REST API with other Salesforce REST APIs. To build UI for creating, reading, updating, and deleting records, including building UI for list views, actions, and dependent picklists, use User Interface API. To build UI for Chatter, communities, or recommendations, use Chatter REST API. If you have many records to process, consider using Bulk API, which is based on REST principles and optimized for large sets of data.

 

For more details about integration and API in salesforce please refer Salesforce Integration Interview questions and answers

Permanent link to this article: http://www.sfdcpoint.com/salesforce/what-is-an-api/

5 Reasons to Take up Marketing Cloud Certification

5 Reasons to Take up Marketing Cloud Certification

Salesforce created history in the field of technology. The success of salesforce products and solutions have been so high that thousands of companies and millions of customers are signing contracts and getting associated with salesforce every day. Getting a marketing cloud certification from salesforce will give you the privilege lead organization to greatness. Newbies will seek your guide in knowing things about cloud development and organization will rely on you to make strategic decisions.

What is salesforce?

Salesforce is an American based company that has revolutionized the world with its unique CRM software. The user interface of Salesforce CRM is clean, and customer problems are treated within a response time of minutes. This is the reason most of the fortune companies use salesforce CRM rather than other CRM, which is available in the market. Now to use the salesforce CRM, an individual would be needed that would have a salesforce certification. This is the reason why salesforce can create millions of jobs worldwide.
Companies are ready to work with people who have salesforce certification since that would mean individual have great technical skills to handle CRM software. Salesforce has three sections, which are regarded as administrators, Salesforce consultants, and developers. Salesforce administrators will have a very different job rather a salesforce administrator. Similarly, a developer will have very different job role than the consultant and the administrator. In order get a marketing cloud developer certification from salesforce you need to have sit for salesforce certification exam.

Salesforce certification exam

Salesforce certification exam is a test to know your love for cloud development. The exam will evaluate your skills as a developer. So, this means before appearing for the test you need to have clear understanding of certain things. Things like data integration, data mining, data extensions should be understood in detail so that you can take up the test with ease. Also, the test will check your skills on data modeling, security and programming languages.

The need for marketing cloud certification

Recent studies have shown that salesforce will create millions of jobs by 2021. So not learning about the salesforce will be a no brainer. A marketing cloud developer of salesforce has huge demand since fortune companies are looking for talented salesforce developer. This article is going you state top 5 reasons why you should get marketing cloud developer certification.

1. Will make you a security expert

No company wants their data breached or wants a cybercriminal that asks for ransom performing a malware attack. When you become a marketing cloud developer then you will know about encryption functions to safeguard company’s data. In addition, you will also know the use of access control systems to cause restrictions on people using the company’s information, and have the knowledge to regularly do a cloud backup in case of natural and human-made disaster.

2. chances of getting jobs are higher

Salesforce certification makes a very good impression in Infront of the recruiters. Studies have shown that 80 % of the companies are looking for individuals that have salesforce certification. When the recruiters will a see a marketing cloud developer certification, then that the employer will already know that you don’t need inhouse training to do the job since you have enough talent skills to start the career from day one. Companies will appreciate that you have invested in something that helps in securing computer networks which are at constant threat every day.

3. Will always keep you in the loop

Digital marketing and knowledge of protecting a computer network would be the future of the world. Most of the companies need the organic reach to grow so that they can increase their sales and visibly of the company. To do this they need marketing cloud developers who have immense knowledge digital marketing. The marketing cloud developer should know to drive in more sales in a company. When you will salesforce certified, then such a certification will play a vital role in making your company grow.

4. Will make you a master when others have just started

A marketing cloud developer from salesforce means that the individual has the best possible abilities and talents when it comes to customer relations management. As a Salesforce developer, you will in the position handle complicated tasks with ease. Your career will grow at an alarming rate as salesforce certification will act as a skyrocket.

5. will help you in becoming a subject matter expert

Every organization has different requirements. For instance, a cloud development of an e-commerce company will be different from an IT company that deals with producing software. With you have salesforce certification then you will automatically be a subject matter expert. Organizations will come to you and ask for your suggestions. Once you become a marketing cloud developer then that means you will be able to operate marketing cloud products.

Is salesforce being the only option

No salesforce is not the only option. There is other CRM software that is present in the market. For instance, there is sugar CRM, there is Zoho CRM, and there is oracle CRM. All these CRM certifications will be good, but salesforce certifications have an aura of their own. Companies trust a salesforce professional rather than a professional of any other certification. Since salesforce has haven in the industry for quite some time, it is having huge reputation for itself. Once you become a marketing cloud developer by receiving certification from salesforce you will able to design mobile and social applications with lightning-fast tools. So, salesforce is not the only option, but it indefinitely the best option

Final thoughts

Going through this article, you will realize why salesforce has been successful in creating millions of jobs worldwide. Having a marketing cloud developer from salesforce can skyrocket your career. Your developer skilled will be enhanced, and you will have the chance to stand out from the crowd. So, calm your mind and prepare to take a Salesforce certification exam that will test your skill in cloud development. Once you pass the test, you would upscale your salary package and live the rest of the life having a job security.

Permanent link to this article: http://www.sfdcpoint.com/salesforce/5-reasons-to-take-up-marketing-cloud-certification/

Have you run out of Dynamic Dashboard

Have you run out of Dynamic Dashboard?

Have you run out of Dynamic Dashboard

Have you ever seen this error?

‘You have reached the limit for dashboards run as the logged-in user.’ 

run out of Dynamic Dashboard Error

When you see this error then that means your org has reached the assigned limit for dynamic dashboards. That means you will no longer be able to create dashboards that will run as the logged-in user/ the dashboard viewer.

The following are the default values:

  • Enterprise Edition: up to 5 per organization.
  • Performance and Unlimited Edition: up to 10 per organization.
  • Developer Edition: up to 3 per organization.

If you want to increase the number of dynamic dashboards for your org than you need to pay for it as additional dynamic dashboards come at an additional price.

Or,

You can check if you have any unused dynamic dashboards which you can delete to free up the assigned count for your org.

To search for the Dynamic dashboards within your org you can choose to follow below methods:

Create a custom report on Dashboards

  1. In setup, search for Report Types and click “new custom Type”.
  2. Primary Object -> Dashboard. Give the report type a description and choose a category to store the report type.

run out of Dynamic Dashboard Report Type1

run out of Dynamic Dashboard Report Type 2

  1. Select Deployed checkbox and click on Next.
  2. When the page reloads click on save.
  3. Go to your app and start creating a report by clicking on New Report.

run out of Dynamic Dashboard Report Type Choose

  1. Select Dashboard as your report type.
  2. Add the Filter in the report as – Dashboard running user = Run as logged-in user, let authorised users change running user.
    run out of Dynamic Dashboard Report Setting
  3. Click apply and run report.

 

Use Workbench

  1. Go to Workbench
  2. Tick I agree to the terms of service
  3. Click Login with Salesforce
  4. Choose “SOQL Query” on Jump to. Query would look like this – SELECT FolderName,Title FROM Dashboard WHERE Type = ‘LoggedInUser’ OR Type = ‘MyTeamUser’

 

  1. Choose “Dashboard” for the Object.
  2. Hit Select
  3. Choose the columns you want to show on under Fields
  4. Filter results by Type = LoggedInUser

 

Other options you can choose:

  1. Determine which dashboard settings you can change from the dashboard viewer to any other option. This will help reduce the count towards your org limit. You can change the setting by editing the dashboard and clicking on the settings button
    run out of Dynamic Dashboard Report Property
  2. Try to delete the dashboard from the recycle bin if even after deleting you are unable to create dynamic dashboard.

 

Permanent link to this article: http://www.sfdcpoint.com/salesforce/have-you-run-out-of-dynamic-dashboard/

Custom Metadata Types salesforce

Custom Metadata Types salesforce

What are Custom Metadata Types?

Custom metadata type in salesforce is customizable, deployable, packageable, and upgradeable application metadata. Custom metadata types are mainly used for app configuration. Custom Metadata Types are similar to Custom Settings in Salesforce, except that they are deployable and packagable. First, you create a custom metadata type, which defines the form of the application metadata. Then you build reusable functionality that determines the behavior based on metadata of that type.

Custom Metadata Types salesforce

 

After you create a public custom metadata type, you or others can declaratively create custom metadata records that are defined by that type. When you package a public custom metadata type, customers who install the package can add their own records to the metadata type. Your reusable functionality reads your custom metadata and uses it to produce customized application behavior. For example, you can use custom metadata types for the following.

  • Mappings—Create associations between different objects, such as a custom metadata type that assigns cities, states, or provinces to particular regions in a country.
  • Business rules—Combine configuration records with custom functionality. Use custom metadata types along with some Apex code to route payments to the correct endpoint.
  • Master data—Let’s say that your org uses a standard accounting app. Create a custom metadata type that defines custom charges, like duties and VAT rates. If you include this type as part of an extension package, subscriber orgs can reference the master data.
  • Whitelists—Manage lists, such as approved donors and pre-approved vendors.
  • Secrets—Store information, like API keys, in your protected custom metadata types within a package.

Custom metadata rows resemble custom object rows in structure. You create, edit, and delete custom metadata rows in Metadata API or in Setup. Because the records are metadata, you can migrate them using packages or Metadata API tools.

Difference Between Custom Settings and Custom Metadata Types

Main difference between custom metadata and custom setting is that custom metadata records are deployable and packagable. But we can not deploy custom setting data.

Here is list of Difference Between Custom Settings and Custom Metadata Types

  • Custom settings enable you to create custom sets of data, as well as create and associate custom data for an organization, profile, or specific user. All custom settings data is exposed in the application cache, which enables efficient access without the cost of repeated queries to the database. Custom metadata are like custom setting but records in custom metadata type considered as metadata rather than data. These are typically used to define application configurations that need to be migrated from one environment to another, or packaged and installed.
  • There are 2 types of custom setting List and Hierarchy Custom setting. There are no such types in custom metadata. Custom metadata does not support Hierarchy type of data based on user profile or specific user.
  • You can control the visibility of custom setting by specifying it as public or protected. If custom setting is marked as protected, the subscriber organization will not be able to access the custom setting. If it is marked as public, then subscriber org can also access it.  You can control the visibility of Custom Metadata Types by specifying it as public or protected. If it is marked as public type, then anyone can see it. If it is marked as protected type, in the installed managed package subscriber organization, only Apex code in that managed package can use it.
  • Custom settings do not support relationship fields. You can create lookups between Custom Metadata objects.
  • You can access custom setting data using instance methods and can avoid SOQL queries to database. With custom metadata types, you can issue unlimited Salesforce Object Query Language (SOQL) queries for each Apex transaction.
  • Custom metadata type are visible in test class without “SeeAllData” annotation but custom setting data is not visible.
  • Custom metadata records are deployable but custom setting data is not.

 

For more details refer to official link and custom metadata type trailhead

Permanent link to this article: http://www.sfdcpoint.com/salesforce/custom-metadata-types-salesforce/

Salesforce Implementation Guide

Salesforce Implementation Guide

How to implement Salesforce CRM?

No matter how big or small your company—or the Salesforce CRM project—success requires planning, commitment, and strong sponsorship from your company’s executive team. It’s also critical that you understand the needs of your managers and users before getting started. Without a detailed understanding of these needs, it’s easy to go overboard in customizing the application just because it’s so easy.

Salesforce CRM Implementation Steps and  Best Practices

You might be thinking to yourself, “I don’t need a consultant — my organization can handle an implementation, no problem.” That may very well be true, but unless you have the internal expertise and resources to handle a large-scale Salesforce implementation, it’ll likely take you a lot longer and cost more to self-implement. And, should things go wrong along the way, you won’t have the professional support you need to get your project back on track. All of this could result in a faulty implementation and a low ROI — so, why take the risk.

Let’s say you want to start with CRM implementation in your company or you want to consult your customer ask 3 Questions to yourself:

  • What? – What is Salesforce CRM?
  • Why? – Why is Salesforce CRM needed? how will it help you to achieve your goals?
  • How? – how will you be able to make your project successful with the right kind of resources and process implementation?

How to Implement Salesforce CRM?

Here is list of key steps for Salesforce crm implementation:

  • Plan and prepare
  • Set up and customize
  • Deploy Salesforce CRM
  • Drive adoption
  • Continuously improve.

Salesforce Implementation

 

Step 1: Plan & Prepare

Planning is very crucial for the success of the Project. It has been a proven fact that Planning internally as a Customer becomes crucial for the success of the Project.

Here is list of steps for Salesforce crm implementation planning

  • Find an Executive Sponsor
  • Team Structure / Resource Planning
  • Set Metrics for Success
  • Project Methodology
  • Build a Project Plan

Find an executive sponsor

The executive sponsor lends their influence to the project by becoming its champion. According to Salesforce MVP and implementation expert, Tal Frankfurt, “Having that person’s full support and participation—from the planning stage until the go-live date and beyond—is absolutely critical.”

Team Structure/ Resource Planning

It is very important to organize a team and to know the resources needed before you start the implementation. This helps you better plan the implementation and lead toward success. The size and scope of your rollout will determine how many resources you need. However, all project teams should include the following participants:

  • One or more system administrators  – This person should be involved throughout the implementation and afterward. It’s important that the administrator understands the business processes and requirements from managers and users.
  • A project manager – This person leads the implementation and makes sure the project tasks and overall timeline are on track
  • One or more power users – These users help make sure your project will meet the needs of the end-users, including management. We also recommend that you use power users as first-line support. To fill that role, consider training these users first and then providing more in-depth training.
  • One or more trainers – Trainers need to identify relevant materials from salesforce.com or develop custom training materials (such as quick-reference guides). You’ll need materials both for the initial implementation to onboard new users and once the application is live, for remediation or for new functionality.
  • Implementation team – Are you capable of implementing it in-house or do you need a consultant? Make sure before you make a decision of implementing in-house you have all the salesforce expertise. Usually, an implementation team consists of a Developers, Configuration Engineer,  Business Analyst, Solution Architect, Deployment Engineer.

Set Metrics for Success

It is very important to set a realistic goal and measurement of success.

You should approach CRM implementation with specific, measurable goals. These goals should be articulated before shopping for a CRM program even begins. Anyone who has taken a goal-setting seminar (and who in sales hasn’t?) knows about SMART goals, goals that are:

  • Specific
  • Measurable
  • Achievable
  • Realistic
  • Time-based

Your Salesforce CRM implementation will be an ongoing, living process. To get the most from your investment, it’s important to roll out functionality early and often. Start with small goals that track against your overall vision. We recommend that you “crawl, walk, run” by keeping your goals simple and attainable and then adding to your achievements.

Project Methodology

The two most widely used approaches are the ‘waterfall’ and ‘scrum’ methodologies. The waterfall is the traditional, phased, sequential approach that may lead to a drawn-out implementation timeline. The scrum approach is to constantly build and deliver small units of functionality and revisit and refine them with each cycle.

Salesforce.com uses the more iterative scrum approach for its development. With Salesforce regular releases (spring, summer, winter) we deliver new enhancements as soon as we have a baseline of functionality and then build and refine the functionality based on user feedback and use cases. For example, Salesforce quoting module was first delivered as a pilot with limited functionality. Salesforce added additional functionality in the next release as a beta release. In the next release, Salesforce added even more features and made it generally available. Salesforce continues to add additional features as customers use quoting and let Salesforce know what you want.

Build a Project Timeline

Once you’ve chosen an implementation approach and prioritized all requirements, you can build the project timeline. Every timeline needs to include the time required to design, build, and deploy. Prioritization of requirements is also key to ensure any ‘must-haves’ are included in the first phase of rollout.

If you use a scrum approach, your timeline will consist of short iterations of the design, build, and deployment phases for a smaller set of requirements. With the waterfall approach, the design and build phase includes all requirements prioritized for the initial deployment. For both approaches, consider what tasks can be done in parallels, such as cleaning, mapping, and loading data.

Below points to Remember:

  • Use Project Management tools like SmartsheetTrello or Basecamp.
  • consider each requirement and estimate the effort required.
  • Plan Contingency.
  • Current System Rollout plan

Define Business Process

The next step is to interview a subset of those team members, so you can gain a greater understanding of the pain points they experience on a day-to-day basis. These interviews will also give you an idea of what these teams want out of a Salesforce implementation — in other words, what features and functionality they think will bring them the greatest value. These interviews should occur at every level of business, from managers and stakeholders all the way down to end-users.

Let’s say, for example, that you talk to key members of your sales team and learn that they struggle to effectively qualify leads due to a lack of insight into each lead. As a result, your sales representatives consistently pursue the wrong leads, wasting time and resources in the process. Based on this conversation, you can identify both the problem and a potentially workable solution, such as implementing — or, if you already have one, upgrading — a customer relationship management (CRM) system so that your sales team can gain a true 360-degree view of each lead in the pipeline.

Interviewing key team members is a simple, yet effective way to figure out which business processes your Salesforce implementation project plan should focus on, as well as to ensure user adoption further down the road.

Step 2: Setup & Customize Salesforce CRM

Once you define your requirements, understand your data, and choose an implementation method, you’re ready to set up and customize Salesforce CRM. We recommend you keep the initial implementation simple and use the ‘click-not-code’ built-in configuration tools, rather than using Force.com code (Apex) and the functionality of the pages of the Force.com platform. As you get to experience with the application and feedback from your users, consider how to enhance the application with those tools.

Define early how to customize the application. For example, if you need multiple record types for an object and field-level security, identifying that need helps as you create new custom fields and associate them to the correct record type, page layout, and security level in the wizard.

Be careful not to over-configure. For example, one customer created many new fields on its contacts page, which meant users had to scroll—a lot. As a result, they didn’t fill out many fields and the company had started over with designing that page.

Here’s a suggested approach for setting up and customizing Salesforce CRM:

  • Define the security settings – Include the organization’s wide-defaults, roles, and user profiles. Test those settings by logging in with different roles and profiles. Make sure each user type can see, create, and edit information as needed, that the fields are in the right order, and that critical fields are required. Another important step is mapping all the roles to the users who will be added to the system, to ensure all users are associated with the correct roles when you go live.
  • Customize the application – Create custom fields, page layouts, custom objects, custom tabs, rules, and other application customizations based on the design for each requirement to meet the business needs.
  • Create your reports – We recommend that you start with the standard reports and customize them as needed to show the information you defined in the planning stage. You can easily customize reports to include any custom fields you need.

 

Step 3: Deploy Salesforce CRM

Once you feel confident in the solution and the architecture, and your users seem to like it, you’re ready to prepare for go-live.

Prepare Go Live:

  • Move your entire configuration to a full sandbox environment to see how it performs under large data volumes. A full sandbox — as opposed to a partial or developer sandbox — is a test environment that contains an exact replica of your production data (customer information, deals, and so on). This enables you to simulate how your configuration will run in a production environment, so you can identify and resolve potential issues such as heat barriers, runtime errors, latency, and downtime prior to go-live.
  • Develop a go-live checklist. This list should include all of the pieces you’ve configured, all of the data transformations that need to occur, and all of the integrations that need to be rebuilt in your production environment. Ascribe an order to this list so that when the time comes to deploy the implementation, everything is deployed in the correct order. There are a lot of dependencies in Salesforce, and certain configurations can’t be deployed before others. The go-live checklist should also identify the method of deployment you intend to use.

Communicate to End Users:

It’s important to communicate early and often, so users know about coming changes. Communication should come from the executive sponsor and focus on both the benefits to the company and what’s in it for the users. Build excitement and set expectations. As the deployment draws nearer, outline the deployment plan, including when users will be trained and how they’ll be supported.

Add Users

Before loading your production data, first load all users. You can load users manually, one at a time, or with the data loader functionality. We recommend you first load all users and data in a sandbox environment before loading the final set of data into your production environment. (Unlimited Edition includes sandboxes; for all other editions, you can purchase sandboxes for an additional fee. Please contact your account executive for more information.)

If you load users with the data loader, the password notification is not automatically sent out. That’s good because you don’t want to send out passwords until users have been trained and you’re ready for them to log in. If you add users manually, you can select whether the user is notified.

Develop a Change Management Process

Change management is an essential part of any implementation because it tells your constituent base what to expect, invests in the project, and empowers them for success. For example, if you’re making upgrades to your existing Salesforce implementation, your change management strategy should communicate to end-users how long Salesforce will be down — or, better yet, eliminate downtime entirely — and how they should track data until they’re able to log back in. If you’re deploying Salesforce for the very first time, your change management strategy should explain to end-users how they’ll benefit from the new systems and which training courses they should take to get up to speed.

It’s also essential to get executive leadership involved in the change management process.

Import data

Because data is loaded at a specific time, the transition will be easier if the data load is as close to deployment as possible. Be sure you schedule enough time to map and test the data. Here’s a summary of the steps involved in importing data:

  1. Plan your data import
  2. Prepare your data
  3. Test the import
  4. Execute the import
  5. Validate your data

Note: If users are still entering data into an existing system after the initial data load but before the go-live or cutover, there may be a set up “delta” data set. You’ll need to import or manually load that data and incorporate it into any training exercises.

Train end-users

Training end-users is key for the adoption of the tool. If you have a sandbox environment, you can train end-users around the same time you load your data. Use a subset of data—or data developed specifically for training—and plan training with hands-on exercises as close as possible to the go-live date. The sooner users can begin to use the application, the better; that way they can get immediate help in response to any questions. Create a Training plan with details as mentioned in the Salesforce tips

Step 4: Drive Adoption

CRM adoption is positively correlated with sales success Once you’re up and running, it’s critical to get your users on board. To do so, it’s important that you support your users, measure adoption, and encourage adoption.

Three other characteristics in addition to advanced CRM that must be in play for a sales organization to be successful:

  • Sales processes must be formal and dynamic.
  • Sales processes need to be adopted by the organization’s sellers.
  • Customer relationships should reflect salespeople as strategic advisors or trusted partners.

Measuring adoption is critical, both immediately after go-live and over time. Set up usage reports and use adoption dashboards to track progress right from the start. You’ll find adoption dashboards on the AppExchange.

Step 5: Maintain the System

As salesforce release 3 times a year and brings really cool features that will help you to take your implementation at the next level and improve as you use it.

Once your users are in Salesforce, you want to keep them there. That’s why inspiring CRM adoption is so important. Your post-implementation plan should not just be about technology, but about the people who use it. Be extremely responsive to users’ questions and challenges, and try to support them in real-time. Refer them to your documentation and add their questions to your feedback list if you haven’t addressed it in your documentation.

Once Salesforce CRM is live, a new cycle of planning begins for the next phase, as you make available new functionality to add value and respond to user requests. Release management should begin as soon as possible after the initial deployment. This approach will also let end users know that you’re addressing their needs and requests.

For more details, please refer this link

All the Best 🙂

Permanent link to this article: http://www.sfdcpoint.com/salesforce/salesforce-implementation-guide/

Lookup Screen Component in Salesforce Lightning Flow

Lookup Screen Component in Salesforce Lightning Flow

Lookup Screen Component in Salesforce Lightning Flow: Salesforce has released a new screen component – Lookup. As the name suggests, this new screen component lets users search for a record in a flow just like a lookup field in Salesforce.

Before this, the only option to select a record in the flow was to use the picklist screen component and each picklist value will denote a separate record of an object.

Using the lookup screen component users can easily search and define the record in the flow and you can also set the current recordID or default value in the lookup field in the flow so that users don’t have to select the record every time they are running the flow from a record.

How to Use the Lookup Screen Component in Salesforce Lightning Flow?

Let’s consider a use case where you need to create a screen flow and want to get some input from the users. And once the flow is executed you want to create a record from the user’s inputs and get it related to a parent object.

In my case, I have a survey object which has a lookup relationship with the account. On the account page, I want the users to go through a set of screens and then the flow will create a Survey record and show as a related list on the account page once the flow is executed. For that, we need to link the survey record to the account record by mentioning a value on the lookup field in the flow.

Lookup in Salesforce Lightning Flow

In the above screenshot, I have added a lookup field by the name of Account since I want to display the account records in my lookup field.

Field API name – Enter the API name of the field which is a lookup field to the object of which you want to show the records. In my survey object, I have a field by the API name AccountName__c which is a lookup to accounts.

Label – Field label of the lookup field which appears on the flow screen.

Object API name – The API name of the source object. The object where the field API name is present.

Record id – Record ID value for the lookup. You can mention the current record id so that by default the lookup field shows the current record from which the flow is executed.

Require – Requires users to enter a value before they can move to the next screen.

Lookup Component in Salesforce Flows

Store lookup values in the flow

When you add a screen component to flow, the values are automatically stored in a variable. When the user navigates to the next screen, the values are assigned to the flow variable.

To store values manually, select manually assign variables (advanced).

All attributes are available to store inflow variables, but most likely you must store this attribute.

ATTRIBUTE DESCRIPTION
Record ID The ID of the record that the user selects.

You can store this value in a text variable.

Record Name The name of the record that the user selects.

You can store this value in a text variable.

 

Permanent link to this article: http://www.sfdcpoint.com/salesforce/lookup-screen-component-in-salesforce-lightning-flow/