Asynchronous Apex
Asynchronous Apex in Salesforce allows developers to execute operations in a separate thread, enabling tasks to run in the background without impacting the user experience. This approach is particularly beneficial for handling long-running processes, callouts to external systems, and operations
Salesforce | Show Email sent from Salesforce in activity history
Problem : How to show Email sent from Salesforce in activity history of an object Solution : Here are the steps : 1. Set WhatId 2. Make SaveAsActivity true Code Sample: Messaging.SingleEmailMessage emailTobeSent = new Messaging.SingleEmailMessage(); List ToAddress = new
Cookie messages on websites and cookie law
Why some sites show cookies message (like this site uses cookies, do you accept?) – is it required, if yes then which body recommends it? Many websites use cookie messages to store information which is required by them for fulfilling
How to create WSDL web service client using Maven
Maven provides apache cxf plugin to generate web service client. We have used below code in our pom.xml file to generate java artifact classes (web service client). There are two ways to generate client code: Using complete WSDL URL Using
MySQL | Insert multiple records and update if record(s) already exist in a single query
In MySQL, we generally perform insert, update, select and delete operations on records of table. Multiple Insert operation can also be easily performed on table. Take an example of Employees table with fields: Multiple records can be inserted in Employees
Data Cleansing
Data Hygiene or Data Cleansing or Data Cleaning – call it by the name you prefer – all point to the process of making the data better than it is before the process is applied. “Better data” means removing what
Cordova/Phonegap | How to fix footer at bottom when virtual keyboard is opened
Problem : Footer is not visible or fixed at bottom, when virtual keyboard is opened in Phonegap/Cordova Application. Solution : Consider following div create for footer : <div data-role=”footer” data-position=”fixed” class=’custom_footer’ data-theme=’b’ data-tap-toggle=”false”></div> To keep Footer fixed at bottom and
Salesforce | Show picklist field value of custom object on Visualforce page
We can show the picklist field value on Visualforce page in a selectlist ( dropdown) using the following code in the controller class: public class classname { public List<SelectOption> selectItemsList() { List<SelectOption> selectOptions = new List<SelectOption>(); Schema.DescribeFieldResult describeResult = CustomObject__c.PickListFieldName__c.getDescribe();
Linux | How to grep only uncommented contents from any configuration file
Problem : How to grep only uncommented contents from any configuration file which is big in size, has many comments and blank lines Solution: This can be achieved by following single command : # grep -v ‘^$’ /etc/httpd/conf/httpd.conf | grep
Netsuite | Invalid email address or account number error on NetSuite, but passed correct credentials
ERROR: Invalid email address or account number error on NetSuite, but passed correct credentials. Need to authenticate NetSuite sandbox account through java application and fetch all the contacts. Below is the link to the WSDL file used to log in: