20 votes
Accepted

Triggers on ContentObjects

Alright, I spent a couple of days going through it all, and the short answer is: it's complicated. Depending on what you want your triggers to do, you may need to have different triggers on different ...
user avatar
18 votes
Accepted

Is Username Globally Unique?

Salesforce is split across login "domains." Each domain uses its own username index, which means it's entirely possible to create the exact same user on login.salesforce.com, test.salesforce.com, and ...
user avatar
  • 433k
13 votes
Accepted

Can someone please explain what is meant by sObject?

An SObject represents a specific table in the database that you can discretely query. The API Name is what you reference as ending in __c. Standard SObjects have names like Account or Opportunity, ...
user avatar
  • 143k
13 votes

Which standard objects don't support triggers?

Following Standard objects don't support trigger, I have gathered so far as of Spring' 17 release. AcceptedEventRelation AccountContactRelation AccountCleanInfo AccountContactRole AccountFeed ...
user avatar
13 votes
Accepted

What is the value of the first and final record id for an object?

Most of what you need to know is covered in What are Salesforce ID's composed of? In short, only the last 9 characters of the ID are incremented from record to record. E.g. 0010a0000000001 to ...
user avatar
12 votes

What is the Opportunity Product?

Opportunity Product (API name OpportunityLineItem) is a Junction Object between Opportunity and Product2 . An opportunity has to be linked to the Product for generating order or to do Quote ...
user avatar
12 votes
Accepted

How to get Standard and Custom Object List in Apex class

Here is updated code that will give list of all objects excluding Share, history , Tag & feed. You can add extra condition to filter out other unnecessary sObjects. List<string> SObjectList =...
user avatar
  • 8,970
11 votes
Accepted

Relationship between Opportunity, OpportunityLineItems(Opportunity Product), PricebookEntry, Product2 & Pricebookentry in Salesforce?

Both points are correct, see here ERD: https://developer.salesforce.com/docs/atlas.en-us.api.meta/api/sforce_api_erd_products.htm
user avatar
  • 2,089
10 votes
Accepted

List of User fields not available in Apex

I tried to relate API Name with UI label and here is what I found. Missing field in API but Available on UI Accessibility Mode NewsAllow Forecasting Color-Blind Palette on Charts End of day ...
user avatar
  • 8,970
10 votes
Accepted

Search for a field in all objects

SOQL/SOSL won't help you here. You can, however, write a query using the Tooling API like this: SELECT Id,TableEnumOrId FROM CustomField WHERE DeveloperName = 'Owner' The easiest way to do this is ...
user avatar
  • 433k
9 votes
Accepted

Custom field in standard object not available in reports on that object

One of three possibilities: You're customizing a report based on a custom report type that doesn't include this field. To resolve, go to Setup / Create / Report Types and add the field. Your ...
user avatar
  • 433k
9 votes

Determine if instance has Multi-Currency Enabled

Boolean multiCurrencyEnabled = Schema.getGlobalDescribe().containsKey('CurrencyType'); If this check is true, it's safe to use CurrencyIsoCode fields and the CurrencyType object. I'd recommend using ...
user avatar
  • 433k
7 votes

Tab Settings Not Available on Permission Set

I encountered same issue. And the solution which worked for me was that while creating the permission set I was not selecting any User License in the picklist. I created a new permission set with User ...
user avatar
  • 86
7 votes
Accepted

How to query FieldDefinition records?

The error message is not very user friendly but what it hints is to provide at least one filter while querying FieldDefinition. For example you can filter the query by using EntityDefinition ...
user avatar
  • 1,732
7 votes

Solutions vs. Knowledge Base

First to start with: The only benefit of Solution over Knowledge Base is: Solution is free!! Now how knowledge beat solution big time or can say why salesforce is making more money by introducing ...
user avatar
  • 507
7 votes
Accepted

How to Link to a Record View?

So @Monith's answer is correct in that you should use an outputLink tag, but I disagree with the link construction methodology enough to post a separate answer. When you are constructing links for ...
user avatar
  • 143k
7 votes
Accepted

How can I create an Account Note or Contact Note via API that is visible in Salesforce UI?

You have the 'new' Notes functionality configured. See: What’s the Difference Between Notes and the Old Note-Taking Tool? With new Notes, you have to use the ContentNote object, then create a ...
user avatar
  • 16.2k
7 votes
Accepted

Can I rename API names of fields in a change set?

The API names are, in a matter of speaking, the unique Id's for your metadata. If you change the API name in sandbox 1, sandbox 2 has no idea that you did that. So when you move the metadata to ...
user avatar
6 votes
Accepted

Removing "Account Name" field from Contact

You can Do This, Just Remove Field Level Security for all the Profile( Including System Admin ), Once you removed it will be there in page layout editor, but It won't be "Visible" In End User View. ...
user avatar
  • 948
6 votes

Why isn't OrderProduct TotalPrice standard field available in formula merge field list

I took a look and couldn't see it either. I did a bit of research in the Spring '14 release notes and nothing there referenced why a field like that wouldn't be available. TotalPrice appears to be a ...
user avatar
  • 19.5k
6 votes
Accepted

Queues, Email Notifications, Standard Controller Extensions. Oh My!

Congratulations. You found one of the ways that StandardController (and StandardSetController) is broken (at least, for now). I've been trying to get a straight answer about why it's as broken as it ...
user avatar
  • 433k
6 votes
Accepted

What Standard Objects Are Missing System/Audit Fields?

Approach I ran this script to find the standard objects missing each field: for (SObjectType sObjectType : Schema.getGlobalDescribe().values()) { DescribeSObjectResult describe = sObjectType....
user avatar
  • 143k
6 votes

How To Deploy Standard Field & Permissions?

There is currently no way to perform this task if you are exclusively using change sets. This is something which will have to be manually done via the point and click interface for every profile / ...
user avatar
  • 2,113
6 votes

Fire Journey Builder when Contact Object is Updated

The documentation is a little misleading when it states: "The rule does not run when a record that previously met rule criteria is updated". Makes it sound like a record can't qualify again. So for ...
user avatar
6 votes

Remove standard objects

You can't delete the definitions of standard objects. If you don't want them to be available to your users under any circumstances, you should remove all object-level permissions ("CRUD") from all ...
user avatar
  • 86.8k
6 votes
Accepted

Fields can see in workbench but when i query it says no such column on entity

MediumPhotoUrl field on User was introduced in API v37.0. If your Apex class has api version lower than that, you won't be able to query that field. Solution: Increase the API version of Apex class ...
user avatar
6 votes
Accepted

Salesforce opportunity stages

Check out the OpportunityStage object. SELECT MasterLabel, DefaultProbability, ForecastCategory, IsClosed, IsWon FROM OpportunityStage
user avatar
  • 143k
5 votes

How to link Single Contact to Multiple Account?

With AccountContactRole object. It's a related list under Account, you might have it hidden on the page layout. Check the help: https://help.salesforce.com/HTViewHelpDoc?id=contactroles.htm and the ...
user avatar
  • 23.6k
5 votes

How to list down all Standard/Custom Objects and ignore System(Internal) Objects

Though not 100% an answer, but based on various posts and comments (like one from @Andrew), below is solution which will give you list of all standard and custom objects ignoring system objects: ...
user avatar
  • 1,099
5 votes
Accepted

Can we write trigger on LoginHistory object

You can't create a trigger on LoginHistory object. But as workaround you can create a scheduled apex which will query LoginHistory objects global class CopyLoginHistory implements Schedulable { ...
user avatar

Only top scored, non community-wiki answers of a minimum length are eligible