What is Apex in Salesforce?

Deepika Khanna
A free video tutorial from Deepika Khanna
Software Developer,Blogger,Author
4.4 instructor rating • 31 courses • 91,572 students

Learn more from the full course

Salesforce Development Training for Beginners

Salesforce Development :Learn about Apex programming and Salesforce development. Become a Salesforce Developer.

13:50:14 of on-demand video • Updated April 2021

  • you will have a mastery of programming in Apex no matter what level of experience you are at right now.
  • My goal is not just to show you how to program, but to help you understand what you are doing, and why you are doing it as well!
  • Not only do the videos show you how to become a Apex programmer in great detail, but this course also contains lot of assignments to practice.
  • I'll be constantly adding new material to the course as well as updating it on a regular basis to make sure you access to the best and most update to date and comprehensive Apex training
English [Auto] Hello guys. This is the picture from my tutorial. Dot com in this tutorial we will talk about what is Apex and what are the different features of Apex language. Now the first thing is what is Apex now apex is a programming language used by sales force developers. So as you know that sales force gives you lot of the out of the box functionalities to achieve your business requirements. But if there is something if there is a requirement that you cannot achieve using the out of the box functionality like using workflows or process builder etc then in that case in order to achieve that business requirement you will need to write some code and the language that you will use in order to write that call is called as Apex. So it's a programming language which is used by Salesforce developers to write a business logic or give it cannot be done using the out of the box functionality of Salesforce apex is a strongly typed object oriented programming language. Now what do you mean by strongly typed strongly typed means that if you are using any kind of data or any variable or constant inside of it it picks program then you have to define the data type of that variable before you can use that variable inside of your Epix program. So if you're not familiar with the variables are constant etc.. Don't worry you're going to cover all that but just bear with me for next couple of lectures and everything will fall into place. So that is what is the meaning of a strongly typed programming language. Now what is object oriented programming language now Epix is also a object oriented programming language which means that it works around the objects. If you have worked with languages like Java or C++ they are also object oriented. So you create objects which has properties and method inside of it. So that is what the object oriented means so that they are the epics walks around these objects then it is Java like syntax. So it picks is very very similar to Java. So if you're coming from a Java background it will be very easy for you to learn Apex because everything is saying the data types and some of this stuff is different but most of the stuff is very similar to Java and that's why apex is also called as a sister language of Java. And another thing what is Apex it enables the sales force developers to add business logic to system events button clicks record updates. Now what do you mean by that. I've already told if things cannot be done using the out of the box functionality you will write the business you in order to achieve your business requirement you will use it because it enables the sales force developers to add the business logic to system events or button clicks or record updates. What you mean by that is for example. So what did it. What does that mean as if let's say you wanted to achieve something. Whenever a user clicks on this hyperlink so if you wanted to go ahead and open a link or go to a different you are relevant when a user clicks on that link you can write that logic inside off your Epix program. Similarly if you click if the user clicks a button you wanted to do something you wanted to have it you have a business requirement and you can go ahead and do epic scores can be executed from the click of a button. It can be executed on or on a click of a link. It can be executed when a record is modified so you can achieve all those things it picks can be executed means epics language can be called on a click of a button. It can be called by a click of a link or vanity God gets updated etc.. So that is what it picks. It's a programming language very similar to Java. It's object oriented. It has the it's strongly typed language. It gives you the ability to do things which are not which cannot be done using the out of the box features of Salesforce. Now what are the features of Apex Apex has lot of inbuilt features so that you do not have to reinvent things you can just use what Apex has already given to you. So Apex has inbuilt support for the email operations. What do you mean by daemon operations. It's called data manipulation language means if you want to go ahead and manipulate the data means if you want to insert the record into Salesforce if you want to update an existing record into Salesforce if you want to delete a record and Salesforce there are already inbuilt functionality available in Apex which you can use to do manipulate the data also IPv6 has enabled functionality for exception handling. So if you if there is an exception and if you want to handle that exceptions using we have a tried catch blog et cetera. You can create your own custom exceptions all those things are available in Apex Apex is Java like syntax and easy to use. So if you're familiar with Java it's very easy to learn Epix so you have a lot of times people move from Java background to Salesforce developers strongly typed language as they already explained to you anytime you use a variable or a constant inside of Apex you have to first define the data type of that variable in order to use that variable. It's easy to test so Apex has in both functionality for testing you in order to deploy any code to production Salesforce wants you to have 75 percent code coverage which means if you do not have a 75 percent code coverage you cannot push anything in production so you need to make sure Salesforce people want to make sure that you have tested your code thoroughly Okay so that it does not break anything in production. So in order to do that they have certain rules and regulations and one of the rules in order to deploy anything to production those must be 75 percent code coverage should be there. So you have to write test glasses in order to cover your code and how you write test classes and how to all do all that you're going to learn in this course. So another feature of Apex is it upgrades automatically. So Salesforce releases upgrades every couple a couple of months and you do not have to do anything to get those upgrades automatically Salesforce will roll out those new features to all the Orcs. Okay. So you do not have to worry about hey I need to update my my Salesforce is all no Salesforce automatically will go ahead and upgrade all the orcs every couple of months so it automatically upgrades itself so these are the different features of Apex programming. Another important thing is when should developers choose epics. This is very very important. So I wanted to make sure you understand this point very clearly if there is something that you can do using the out of the box functionality in that case you should use out of the box functionality you should not write any court Salesforce does not want you to write any code. If that particular requirement can be fulfilled using the out of the box features if something you can do using workflows or if you can do using visual flaws or if you can use using process builders then you should use those. You should not write triggers or you should not write any Apex glass in order to achieve something which can already be done using the out of the box features of Salesforce. A lot of times I've seen developers doing this mistake by writing code because they like to code and they just write code for everything. You should not do that. It's going to end the end of the day. It's going to be it's going to create a problem if something can be done using the out of the box features then you should use those out of the box features IPv6 should only be used for complex requirements if those things cannot be achieved using the out of the box features. So please keep this point in mind. And because later on this is gonna be very very helpful. Now in the next tutorial we're going to go ahead and deep dive into how does Apex looks. What are the different things that we're going to learn in discourse. So I will see in the next tutorial. Thank you so much.