In Apex, there’s quite a few constraints that are strictly enforced because the platform is a shared multitenant environment. Quite a few of the limits result in runtime exceptions that can’t be handled.
For those familiar with Salesforce, it’s no secret that there’s a lot of limits. For example, there’s limits around the ViewState which were pretty painful to work around.
One of the first limits, I believe all new Salesforce developers hit is the limit for a maximum of SOQL queries that can be done. Continue reading
If you have been programming on the Salesforce/Force.com platform for any amount of time I’m sure you have come into contact with Apex Triggers. If not, Apex Triggers are units of code that execute whenever a database operation occurs. I’ve put together a post about Before and After Triggers that you should read if you aren’t very familiar with how triggers work.
Apex Triggers can get complicated very fast if your company has a very customized Salesforce Org. Apex Trigger Frameworks are a way of offering generic functionality that structures code in a certain way. If you were to use a building metaphor we could say that a framework is the supporting structure of the building – it’s the steel or wood shell that supports the building. Trigger Frameworks are very good at enforcing trigger best practices. Continue reading
As Salesforce Developers and Salesforce Administrators, we need to understand how the system will process and validate the data that we are inserting or manipulating. As any system does, the rules follow a general pattern that’s known as the Salesforce Order of Execution. Continue reading
What’s an Exception
An exception is an unexpected event that occurs when code is executing. Basically apex is signalling there is a problem and that it can’t deal with the issue. Continue reading
In the blog post “What’s the difference between a Lead and Opportunity?” I spent a bit of time covering how leads are converted into accounts, contacts, and opportunities.
Basically, a lead is converted when the sales person thinks that there’s actually an opportunity to sell them something. In a lot of cases, it might make sense of for leads to be automatically converted after a field is set to a certain value. For example, a lot of companies might want to automatically convert a Lead as soon as the Sales Rep has completed ANUM or BANT.
To convert a Lead into an Account, Contact and an Opportuninity we need to make use of the Database.convertLead method.
Salesforce is an incredibly large and customizable platform with hundreds of different features. Learning to use Salesforce can be difficult, but learning to program and manage Salesforce is even more daunting. Below I’ve provided you with the best resources I could find on programming Salesforce. Before jumping into learning to program apex, I recommend you register for a demo org and watch a few of the different product demos.
When I started learning how to use Salesforce Apex in 2013, I was amazed at the hundreds of different online resources available. Literally, there are thousands of different sites. Over the last two years, I’m sure there’s been even more resources. Salesforce has developed its own “learning portal”, and there’s been a few new books that have come out.
One site, in particular really stood out to me which was SALESFORCE CODING LESSONS FOR THE 99%. David has written very good and detailed tutorials that anyone should be able to follow and implement. I understand that David lead some great sessions at Dreamforce 2014; I wasn’t able to attend any of them though.
At Dreamforce 2014, Salesforce introduced Trailhead. A while after Dreamforce, I wrote a post about my thoughts on Trailhead. Trailhead is an incredible resource that I wish was around when I had first started using Salesforce. Over the last year, it’s really exploded and now offering a ton of different paths to learning about Salesforce.
Bob Buzzard Blog
No list would be complete without the Bob Buzzard blog. Keir has written dozens of blog articles that I have bookmarked about different Salesforce topics. His posts are primarily about visualforce and apex, although he has started writing quite a bit about Salesforce Lightning and Trailhead. He’s also written a book about visualforce and led some great sessions at Dreamforce. I believe right now Keir has almost all of the Salesforce Certifications.
Harshit Pandey previously worked at Salesforce as a Technical Architect. He has some incredibly basic blog articles, and some incredibly technical articles as well. One of my favourite series so far is his section on Salesforce Technical Architect Best Practices.
Jeff Douglas Blog
Prior to becoming a Salesforce Employee Jeff wrote some incredible posts about apex and visualforce. One of my favourite posts is his post about having “Fun With Salesforce Collections“.
Additional Salesforce Training Resources
- Force Platform Fundamentals is Salesforce’s introduction to the Force.com Platform. There’s quite a bit of discussion about building metadata (creating objects, fields, custom workflows, approval process), security, and reporting. Overall, it’s pretty good but also very daunting. The pdf has about 400 pages.
- Visualforce Developers Guide is pretty much a must for any developer that will develop pages in Salesforce.
- Apex Workbook covers a lot about the syntax, fundamentals, and limits the Salesforce have placed in the language and on the platform.
- Salesforce University provides some in person and online training. I haven’t taken any of the training, but it seems like it could be pretty good based on some of the Hands on Training I’ve done at Dreamforce. Prices also seem to be pretty high, and in US Dollars
- On Youtube, there’s a lot of different Dreamforce Presentations many of which are very good and still pretty relevant.
- Also review my blog article about about Using jQuery with Visualforce.