Questions tagged [apex]

Apex is a strongly typed, OOP language that allows to execute flow and transaction control statements on the Force.com platform server in conjunction with calls to the Force.com​ API. Not to be confused with Oracle Application Express (APEX) - use tag [oracle-apex] for Oracle APEX questions

Apex is a strongly typed, OOP language that allows to execute flow and transaction control statements on the Force.com platform server in conjunction with calls to the Force.com​ API.

There is synonym for this tag - .

Useful Links:

Apex Intro/Quick Start

2528 questions
0
votes
1 answer

Create trigger that updates row depending on column value from other table

I would like to create a trigger that updates a row in a table (TABLE2) depending on column value from other table (TABLE1). Which line must be updated depends on the ID of TBL1. CREATE OR REPLACE TRIGGER INSERT_PAGE BEFORE UPDATE OR…
user111
  • 137
  • 1
  • 15
0
votes
1 answer

Need to send Whatsapp Messages from Salesforce - Apex Code

I am doing a proof of concept to find a way to make callouts from Apex code to send automated Whatsapp messages/communications from Salesforce to our customers at difference points of time in Sales life cycle (ex: one at lead conversion, one when a…
0
votes
1 answer

Create trigger to insert column depending on value of other column

I would like to insert a value into a column depending on the value of another column in the same table. For this I created the following trigger: create or replace TRIGGER INSERT_COLUMN2_TBL1 BEFORE INSERT OR UPDATE ON TBL1 FOR EACH…
user111
  • 137
  • 1
  • 15
0
votes
1 answer

How to set checkbox to true with Trigger when related objects are created

This is relation between two obj. I want to code a trigger which makes Enrolled field from false to true (unchecked to checked) when Student is created with College record.
K.Vodenicharov
  • 33
  • 1
  • 2
  • 7
0
votes
1 answer

How to Show/Hide button based on Profile in Salesforce LWC

I have develop LWC component which is normally used by normal users. In that lightning web component button is there as below. The above…
lochana
  • 121
  • 3
  • 15
0
votes
0 answers

Triggerhandler class and trigger issue - showing nullpoint exception error

trigger AssignedResourceTrigger on AssignedResource (after insert,after update){ if(trigger.isAfter & AssignedResourceTriggerHandler.isRecursive){ if(trigger.isInsert || trigger.isUpdate){ …
thala
  • 1
0
votes
1 answer

Close Tab After X Amount of Time Apex

I am trying to automatically close a tab in Salesforce after X amount of time. I am doing this through a lightning cmp that is placed onto a record page. The code works, but immediately closes the tab. I'm currently testing with a 9 second wait…
0
votes
1 answer

How can I fix Trigger errors? Oracle 19 Express

I would like to track user activities for a certain table. For this I have created a table in which I can insert the audit data: CREATE TABLE "AUDIT_FINALPAPERS" ( "TBLID" NUMBER, "NAME" VARCHAR2(10), "REMARKS" VARCHAR2(255), …
user111
  • 137
  • 1
  • 15
0
votes
1 answer

Conditional Rendering in Oracle APEX

I want to create conditional rendering in oracle apex. Depending on what the user selects (Employee, Department(these are the displayed values)) for Page Item (P15_CHOICE),I want to display a different region for the regions I have following SQL…
user111
  • 137
  • 1
  • 15
0
votes
1 answer

VisualForce Button not returning Selected Ids

I am converting a custom List JS button to support lighting. So, I've made changes to existing class and created a VF page and added that to the list view button. But when I run the functionality nothing seems to happen and debug logs returned Id as…
roni
  • 1
  • 2
0
votes
1 answer

Pre selected Rows with Pagination not working in Datatable in Saleforce LWC

I am loading the user table data to datatable using LWC, the users who has not logging past two months. When the page loads first time I load all the list to front end and using pagination Im going through the records instead going to the server…
lochana
  • 121
  • 3
  • 15
0
votes
1 answer

Clone Opportunity records with all the fields without using standard clone() method?

I have try to clone Opportunity records and done till 3 fix field But I need for all fields.But without using clone() method. Code - public class Cloningwithout { public static void insertclone(){ Opportunity opp = new…
0
votes
1 answer

LWC, set record to database soql from JavaScript with wire and Apex, error

I try to write something to the database soql in JS, but it not works. When I click to the button 'Add to Cart' then is called handlePlaceOrder(). Here is called Apex method placeOrder('hello') with parameter String. And then it crashed "an internal…
Elo
  • 226
  • 5
  • 19
0
votes
0 answers

System.AsyncException: Database.executeBatch cannot be called from a batch start, batch execute, or future method

Getting the following error while updating a record via an external app. The trigger is calling a batch when this record is getting updated. Update failed. First exception on row 0 with id 0013H000008gq59QAA; first error:…
0
votes
1 answer

Salesforce: Is there a way I can query my custom Commission table to return all the commissions under all contacts under a specific Account

I have a custom Commission table which has a master detail relationship with contact. I have a List of AccountIds being passed into the function and then into the query. I'm getting the error: " Didn't understand relationship 'Contacts' in FROM…
Philip
  • 67
  • 7