Questions tagged [error]
Error - A mistake or Getting unexpected output or Bug
932
questions
31
votes
1
answer
92k
views
Can anybody explain the UNABLE_TO_LOCK_ROW error?
Error Message:
Developer script exception from Nicomatic : quotepotential :
quotepotential: execution of AfterUpdate caused by:
System.DmlException: Update failed. First exception on row 0 with ...
29
votes
2
answers
1k
views
Error handling from JS remoting
We are using JS remoting. Found this interesting race condition:
JS Remoting AJAX request made by user.
Before it completes the user moves to another page
When user moves browser to another page the ...
15
votes
2
answers
12k
views
Failed to create deployment: This container has a save in progress with deploymentId=[YOUR-DEPLOYMENT-ID]
I received this error message yesterday in the Developer Console, preventing me from saving any new code (Apex, Visualforce) for the past 24 hours.
FIELD_INTEGRITY_EXCEPTION
Failed to create ...
14
votes
1
answer
13k
views
Log to console in a Lightning Web Component
I am attempting to write a Lightning Web Component, but continually run into errors in my Javascript that I can't debug.
I've been trying to log my error but when I put console.log() anywhere in the ...
14
votes
2
answers
24k
views
Browser Error: "Refused to set unsafe header 'User Agent'"
Just today I started having a very odd layout issue on our standard Account layout. The org in on the NA6 server. This is the standard layout. It's always happening when I use chrome. I haven't ...
14
votes
0
answers
2k
views
Managed Package error "Dependent class is invalid and needs recompilation"
I'm getting an exception email from a client who has installed my Managed Package in his org. The error message I receive is:
Apex script unhandled trigger exception by user/organization:
...
12
votes
3
answers
337
views
System classes are being shadowed by my Apex classes
When I create a class called Process it looks like I'm experiencing class shadowing. For example:
public class Process {
//...
}
The existence of the above class prevents me implementing the ...
12
votes
2
answers
7k
views
Why does the getErrors() method on DataBase.SaveResult return a List?
Each instance of a Database.SaveResult corresponds to a result of a DML operation on a single record. According to the documentation, the method to get error details for a record actually returns an ...
11
votes
3
answers
56k
views
Apex compile error : variable does not exist
I'm having issues with creating a pretty simple test Utility Class. I want to create two records: an account and a related child contact. The error I see in the developer console is:
Variable does ...
11
votes
1
answer
909
views
Variable is used before it is declared
I've got this line of code:
Pattern pattern = Pattern.compile('(?:([\\w&&[^_]]+)|.)+');
However, I'm getting this error in the Developer Console:
Variable pattern is used before it is ...
11
votes
2
answers
4k
views
Deployment Error on save from Developer Console
I noticed that I cannot save orupdate any code from the Developer Console (Apex Classes, Visualforce...). When I try to save a file, I get an error similar to this one:
An unexpected error has ...
11
votes
1
answer
1k
views
Why do packages have tons of Referenced Packages - often with warnings?
When creating new packages and importing them into the Force.com IDE I recently saw many Referenced Packages which seem to have no connection to my app at all.
I would ignore this if not sometimes it ...
10
votes
5
answers
14k
views
Clear Apex:PageMessages without losing viewstate
Is there a way to clear the PageMessages in my controller without losing my Page's viewstate?
At the moment I'm doing a ajax call from my visualforce page, which rerenders part of my page, but this ...
10
votes
3
answers
14k
views
Error Implementing force:showToast - Cannot read property 'setParams' of undefined
Component
<aura:component implements="force:lightningQuickAction">
<ui:inputNumber aura:id="num1"/> +
<ui:inputNumber aura:id="num2"/>
<br/>
<ui:button ...
10
votes
3
answers
8k
views
How separation of Test Class can solve 101 SOQL Queries Limit Exceeded Error?
Recently one of my colleagues was trying to deploy to production some opportunity trigger activation, but during validation deployment two of ten test methods from TestMyMysteriousApexClass failed ...
10
votes
1
answer
435
views
$Setup cannot resolve protected setting in managed package after Spring 2020
A custom button in a managed package uses a protected custom setting in the same package to retrieve a namespace:
/apex/{!$Setup.Constants.URL_Namespace__c}PageName?param=value
When installed with ...
9
votes
1
answer
595
views
Too many namespaces error
Once in awhile when I try to convert a lead, I get the following error:
Error: System.LimitException: Too many namespaces accessed: 10 External entry point
It happens pretty infrequently and I can'...
9
votes
3
answers
2k
views
Session expired or invalid
I am trying to build Salesforce to Salesforce integration using Named Credentials.
Followed steps from below blog.
http://www.jitendrazaa.com/blog/salesforce/salesforce-to-salesforce-integration-...
9
votes
0
answers
329
views
Managed Package error emails behaviour changed?
I have a First-Generation Managed Package that was updated and released for years. It's current version is 6.0.
I just recent added a User to the Package page to get error notifications as described ...
8
votes
1
answer
2k
views
When is it OK to use apex:pageMessages escape=false?
I want to include a hyperlink in an error message on a Visualforce page.
I read that AppExchange products will fail the security test if apex:pageMessages escape=false is included.
My usage is for ...
8
votes
2
answers
5k
views
"REGEX too Complicated" error
Is "REGEX too Complicated" error while attempting to upload a CSV via Apex into SFDC an undocumented limit? What should be the optimal data volume for a CSV upload via Apex? I was trying with 10,000 ...
8
votes
6
answers
2k
views
Bug with force.com IDE/Eclipse plugin with Spring 14 org's only
On two of my sandboxes I am getting an error every time I open a class or try to open the schema (the classes load but the schema does not). Other org's are working fine but these two, which are from ...
8
votes
1
answer
653
views
Which date format to use with inputs for the Quick Actions REST API? (INVALID_TYPE_ON_FIELD_IN_RECORD)
I'm receiving the error INVALID_TYPE_ON_FIELD_IN_RECORD when invoking a custom sobject quick action to create a record and its payload specifies a Date or DateTime field as an input value.
For ...
7
votes
8
answers
5k
views
Error deploying to org: "Cannot read property 'success' of undefined"
When Deploying anything from VSCode I get the same error everytime. I have created a new project in VSCode using SFDX.
I am able to authorize and retrieve from org, but anytime I deploy I get the same ...
7
votes
2
answers
21k
views
No sfdx-project.json found in the root directory of your open project. Open a Salesforce DX project in VS Code
I'm using VScode for Apex dev. I have logged into Devhub org. and created a scratch org. when I try to execute pallet command:
SFDX: Refresh SObject Definitions
I'm getting below error.
No sfdx-...
7
votes
2
answers
3k
views
Icon maximum length error during deployment
I created a new sandbox and tried to deploy some code changes using Github and CircleCI (CircleCI internally uses Ant Migration Tool).
I get this strange error :
[sfdeploy] Component Failures:
[...
7
votes
1
answer
13k
views
Number of iterations exceeded - Flow Error
I have a flow that loops through Opportunity Line Items. When the number of line items get large it get an error in my flow. The UI gives the following message "You or your organization has exceeded ...
7
votes
2
answers
43k
views
Apex Error: Field is not writeable [duplicate]
I am new to writing Apex Triggers. I wrote this trigger by referring few examples, but now i end-up with ContactAccessLevel field is not writable Error.
Use Case: In contact object, I have a field ...
7
votes
1
answer
360
views
When and why to use $A.reportError?
In the documentation Using JavaScript Promises it is mentioned
To show an error message in a catch() method, use $A.reportError()
Why would I want to use $A.reportError that at all? I could use ...
7
votes
3
answers
798
views
Data Not Available? Can't edit a custom formula field formula
Any ideas why I would get a "Data Not Available" error when editing a custom field?
In this specific instance I'm editing a formula field, and I'm able to edit and save changes to the description and ...
7
votes
1
answer
651
views
INSUFFICIENT_ACCESS_OR_READONLY in Batch class. No error when done outside Batch
I have an odd issue where I am hoping its just something obvious that I am missing, so hoping to get another set of eyes on it.
I have a fairly simple batch class that is looking for CampaignMembers ...
7
votes
1
answer
3k
views
Unable to upload an Attachment - Bulk API
I'm using Bulk API to upload attachments and getting an error:
InvalidBatch : Failed to parse CSV header.
Number of Records Processed: 0
While I'm getting following error at the Salesforce ...
6
votes
2
answers
9k
views
Customize standard error message on the visualforce page
I want to customize the error message box which comes for various errors. i want only a single custom message for all types of errors and also a different custom icon. How can i implement this?
6
votes
2
answers
1k
views
java.sql.SQLException error caused by OpportunityLineItem DML request
In our Salesforce.com organization, we have a trigger on the OpportunityLineItem object (insert/update), automatically generating OpportunityLineItemSchedule. The product is schedule by revenue, ...
6
votes
4
answers
22k
views
How to use Lightning-Record-Form onError to display custom error message
Let's say I have a Lightning-Web-Component that uses lightning-record-form like this:
<lightning-record-form
record-id={recordId}
object-api-name="Opportunity"
fields={myFields}
...
6
votes
2
answers
2k
views
SOQL query causes internal Salesforce error
I've hit an unhandled exception when writing a query, and I'm curious if anyone here has seen the same thing. This is not a timeout issue - the error happens almost immediately, so it's not a query ...
6
votes
1
answer
3k
views
Exact equality operators only allowed for reference types: String
Please find below piece of code where I am getting this error.
Error:
Compile Error: Exact equality operators only allowed for reference
types: String
Code:
if(((inc.Status_abv__c!=='New') || ...
6
votes
2
answers
12k
views
How do I query for the Product Object?
In trying to use a query based on product standard object in a Batch Apex program.
select name from product/products returns error even in Developer console.
Errors :
sObject type 'Product' is ...
6
votes
1
answer
559
views
Where Statement issue with SOQL
I am trying to do the impossible here. I have a parent object that I am querying along with 3 of its child objects. I have filtered each of the child objects and the parent objects based on an input ...
6
votes
3
answers
4k
views
Salesforce SOAP Exception - Expecting Envelop found Fault
I have a problem with parsing a response I am receiving via a SOAP callout in Salesforce. The error I am receiving is : Web service callout failed: Unexpected element. Parser was expecting element '...
6
votes
2
answers
2k
views
Customize the Duplicate Username error message in a Community
When a Community user tries to register using an email address that already exists in the system (using self-registration), they receive a very generic error message:
"Your request cannot be ...
6
votes
2
answers
16k
views
Can we display warning message from Trigger
I am using custom Object, I need a warning message on Detail Page, Is there anyway?
6
votes
1
answer
2k
views
Validation Rule to count words
What
I'm trying to do a validation rule to count number of words in a text field and return an error if field have more than 80 words.
Validation Rule Condition Formula
NOT(REGEX(TRIM( ...
6
votes
1
answer
19k
views
Keep Getting Error "Bad Message 431"
Starting today, I keep getting the error "Bad Message 431", followed by "reason: Request Header Fields Too Large" when I refresh a console page in Salesforce. The page is "https://mycompanyname.my....
6
votes
1
answer
656
views
NinjaValidationException
I encountered the following exception when trying to insert a CollaborationGroup in a test:
System.DmlException: Insert failed. First exception on row 0; first error: UNKNOWN_EXCEPTION, content....
6
votes
1
answer
3k
views
403:denied_by_security_policy:create_denied when subscribing to platform events
This error is thrown when I try to subscribe to a platform event using the EMP-connector. I followed the steps outlined in the documentation:
https://developer.salesforce.com/docs/atlas.en-us.220.0....
6
votes
1
answer
136
views
Cannot migrate deprecated unlocked package2 component since Winter 20'
I am unable to migrate a package2 member from one unlocked package to another.
Before Winter 20', as per these instructions, deprecating a member from the first package and installing the second ...
6
votes
1
answer
2k
views
Error handling when publishing platform events
We are in the process of redesigning our system to use platform events as a replacement of traditional trigger-based approach when all processing happen synchronously sharing single transactional ...
6
votes
0
answers
430
views
No DML_END Issue
Yet another "what gives" question.
I have a custom object that is updated upon a button click on a VisualForce Page.
I can see in my debug logs that the object has been updated. But when I refresh ...
6
votes
2
answers
2k
views
How can we fix the Lightning Component ui:inputDate DatePicker position?
I'm in need of implementing a lightning component that includes ui:inputDate component with displayDatePicker=true.
The component is mainly only for sidebar purposes in Lightning Page. But when I ...