Forum Replies Created

Page 18 of 57
  • We can achieve this using triggers or through relationship among objects

  • If you need to play out any activity after some activity, we can go for Workflow Rule.

    On the off chance that you need to play out any activity when some activity, we can go for Trigger.

  • It isn’t conceivable to refresh records with the same id in a document utilizing upsert task. It will toss “copy ids discovered” blunder.

  • shariq

    Member
    September 22, 2018 at 11:30 AM in reply to: Can you tell me what is time based workflow in Salesforce?

    Time Based work process will be activated at what time we characterize while making the Time-Dependent work process run the show.

  • shariq

    Member
    September 22, 2018 at 11:29 AM in reply to: What is virtual class ?

    In protest situated programming, a virtual class is a settled inward class whose capacities and part factors can be abrogated and reclassified by subclasses of the external class. Virtual classes are closely resembling virtual capacities.

  • shariq

    Member
    September 22, 2018 at 11:29 AM in reply to: What are outbound messages in Salesforce? what it will contain?

    In outbound message contains end point URL.

  • Run the below code in developer console

    List acc =[SELECT Id, Name FROM Account];

    for(Account a : acc)

    {

    a.Name = a.Name.removeEnd(‘Updated’);

    update a;

    }
    (Top 30 Salesforce Apex Interview Questions and Answers Pdf)
    16. How do you pass the parameters from on apex class to another to another ?
    Answer: You can simply pass the parameters through the URL.

    say you are redirecting from one VF page to another

    string value = ‘your param value’;

    string url;

    url = ‘/apex/VF_Page_Name?param1=’ + value;

    PageReference pageRef = new PageReference(url);

    pageRef.setRedirect(true);

    return pageRef;

    Then in the controller of the VF page, you just can get the param like this

    String param_value = system.CurrentPageReference.GetParameters().get(‘param1’);

  • shariq

    Member
    September 22, 2018 at 11:27 AM in reply to: How Can I Tell the Day of the Week of a Date in Salesforce?

    Formulas:

    There isn’t a worked incapacity to do this for you, yet you can make sense of it by checking the days since a date you know. Here’s the idea: I realize that June 29, 1985, was a Saturday. In case I’m endeavoring to make sense of the day of the seven day stretch of July 9 of that year, I subtract the dates to (Pivotal Training) determine the number of days (10) and then use modular division to figure to remove all the multiples of 7. The remainder is the number of days after Saturday (1 = Sunday, 2 = Monday, etc.) and you can use that number in your logic:

    MOD(DATEVALUE( Date_Field__c ) – DATE(1985,7,1),7)

    Apex Code

    You could do the same thing with time deltas, but you can also use the poorly documentedDateTime.format() function:

    // Cast the Date variable into a DateTime

    DateTime myDateTime = (DateTime) myDate;

    String dayOfWeek = myDateTime.format(‘E’);

    // dayOfWeek is Sun, Mon, Tue, etc.

  • Email notice through the trigger or through email ready Workflow run the show.

  • shariq

    Member
    September 22, 2018 at 11:25 AM in reply to: How do you refer to current page id in Salesforce Apex?

    If you want to retrieve id in a visauflrorc page then you can retriev it using standard cotnroller.

    for ex:

    public myControllerExtension(ApexPages.StandardController stdController) {

    this.acct = (Account)stdController.getRecord();

  • shariq

    Member
    September 22, 2018 at 11:24 AM in reply to: Can’t Deploy Due to Errors in 3rd Party Packages in Salesforce?

    It was already conceivable to introduce oversaw bundles and Ignore APEX Test Errors this isn’t the situation any longer.
    You are likely must uninstall them on the off chance that you need to convey from Sandbox to creation and reinstall them
    In the event that it’s Milestones PM (the bundle) is you can most likely get an unmanaged variant to work with and settle the bugs.
    UPDATE:

    It would appear that you are utilizing the unmanaged bundle. So I think on the off chance that you would prefer not to uninstall before going to generate you must fix those blunders physically by settling the code.
    Sadly, SFDC test strategies don’t live in a total vacuum where you can run tests against your organization without knocking other code, notwithstanding when you go to convey

  • shariq

    Member
    September 22, 2018 at 11:23 AM in reply to: How to make picklist as required (thru javascript) in Salesforce ?

    We need to make a custom catch and in that custom catch, we need to compose JavaScript code to check whether the picklist esteem is invalid.

  • You can use triggers.

  • shariq

    Member
    September 22, 2018 at 11:20 AM in reply to: What is abstract class ?

    Abstract classes will be classes that contain at least one dynamic strategies. A conceptual technique is a strategy that is pronounced however contains no usage. Unique classes may not be instantiated, and expect subclasses to give usage to the theoretical techniques

  • shariq

    Member
    September 22, 2018 at 11:19 AM in reply to: In Which object all Apex Triggers are stored ?

    ApexTrigger object

  • shariq

    Member
    September 22, 2018 at 11:18 AM in reply to: What is the use of interfaces(in apex classes)?

    An interface resembles a class in which none of the strategies have been executed—the technique marks are there, yet the body of every strategy is void. To utilize an interface, another class must actualize it by giving a body to the greater part of the techniques contained in the interface.

    Interfaces can give a layer of reflection to your code. They isolate the particular execution of a technique from the announcement for that strategy. Thusly you can have distinctive usage of a strategy in view of your particular application.

    • This reply was modified 7 years, 6 months ago by  shariq.
  • shariq

    Member
    September 22, 2018 at 11:02 AM in reply to: What are getter methods and setter methods?

    Get (getter) method is used to pass values from the controller to the VF page.
    Whereas, the set (setter) method is used to set the value back to controller variable.

    I hope this set of Salesforce interview questions will help you ace your job interview. As the next step for your career, check out the various certifications offered by Salesforce here: Salesforce Certifications. It will also help you to understand the job roles and chalk out a career path for yourself.

    Also, check out this video on the Top 50 Frequently Asked Salesforce Interview Questions which was delivered by an industry expert. He has shared his opinion of Salesforce job interviews and industry demand. Do take a at it look and let us know if this helped in your interview preparation.

  • shariq

    Member
    September 22, 2018 at 11:00 AM in reply to: What is Salesforce Apex transaction?

    An Apex transaction represents a set of operations that are executed as a single unit. The operations here include the DML operations which are responsible for querying records. All the DML operations in a transaction either complete successfully, or if an error occurs even in saving a single record, then the entire transaction is rolled back.

  • shariq

    Member
    September 22, 2018 at 11:00 AM in reply to: What is the difference between SOQL and SOSL in Salesforce?

    The differences are mentioned in the table below:

    SOQL vs SOSL

    SOQL (Salesforce Object Query Language)

    Only one object can be searched at a time

    Can query any type of field

    Can be used in classes and triggers

    DML Operation can be performed on query results

    Returns records

    SOSL (Salesforce Object Search Language)

    Many objects can be searched at a time

    Can query only on email, text or phone

    Can be used in classes, but not triggers

    DML Operation cannot be performed on search results

    Returns fields

  • shariq

    Member
    September 22, 2018 at 10:57 AM in reply to: What is an sObject type in Salesforce Apex?

    An sObject is any object that can be stored in the Force.com platform database. Apex allows the use of generic sObject abstract type to represent any object.

    For example, Vehicle is a generic type and Car, Motor Bike all are concrete types of Vehicle.
    In SFDC, sObject is generic and Account, Opportunity, CustomObject__c are its concrete type

  • shariq

    Member
    September 22, 2018 at 10:57 AM in reply to: What all data types can a Set store in Salesforce?

    Sets can have any of the following data types:

    Primitive types
    Collections
    sObjects
    User-defined types
    Built-in Apex types

  • shariq

    Member
    September 22, 2018 at 10:56 AM in reply to: What is Trigger.new in Salesforce?

    Triger.new in Salesforce is a command which returns the list of records that have been added recently to the sObjects. To be more precise, those records will be returned which are yet to be saved to the database. Note that this sObject list is only available in insert and update triggers, and the records can only be modified in before triggers.

    But just for your information, Trigger.old returns a list of the old versions of the sObject records. Note that this sObject list is only available in update and delete triggers.

  • shariq

    Member
    September 22, 2018 at 10:55 AM in reply to: What is a Visualforce component in Salesforce?

    A Visualforce Component is either a predefined component (standard from component library) or a custom component that determines the user interface behavior. For example, if you want to send the text captured from the Visualforce page to an object in Salesforce, then you need to make use of Visualforce components. Example: <apex:detail>

  • shariq

    Member
    September 22, 2018 at 10:53 AM in reply to: What is the use of “@future” annotation in Salesforce Apex Classes?

    Future annotations are used to identify and execute methods asynchronously. If the method is annotated with “@future”, then it will be executed only when Salesforce has the available resources.

    For example, you can use it while making an asynchronous web service callout to an external service. Whereas without using the annotation, the web service callout is made from the same thread that is executing the Apex code, and no additional processing will occur until that callout is complete (synchronous processing).

  • Collections are the type of variables which can be used to store multiple number of records (data).

    It is useful because Governor Limits restrict the number of records you can retrieve per transaction. Hence, collections can be used to store multiple records in a single variable defined as type collection and by retrieving data in the form of collections, Governor Limits will be in check. Collections are similar to how arrays work.

    There are 3 collection types in Salesforce:

    Lists
    Maps
    Sets
    Maps are used to store data in the form of key-value pairs, where each unique key maps to a single value.
    Syntax: Map<String, String> country_city = new Map<String, String>();

Page 18 of 57