-
Test Database.query
We have our managed package and we need to install in another org. And there are many custom fields which already exist there. So we cannot create the custom field in our org because it will cause the duplicate issue. So how should i write the test method to cover the dynamic query custom fields?
I am using dynamic query to query records like
List<Account> accList = Database.query('select Name,customfield__C from Account');
as customfield__C is not present in my org it's value getting retrieved dynamically , so how to give customfield__C value in my test class.
Log In to reply.
Popular Salesforce Blogs
Einstein GPT: the first generative AI for CRM
Since its release in November 2022, Chat GPT has become a buzzword - over a million people signed up to use it in just five…
What Is Salesforce Workbench - The Complete Developer Guide
What is Salesforce Workbench? Salesforce Workbench is a tool that brings together a number of advanced features and capabilities into one place. A lot of…
Top 10 Salesforce Interview Questions with Answers
The success and prosperity of any modern business depend on its ability to communicate with customers and meet their demands. That is why efficient Customer…
Popular Salesforce Videos
Salesforce For Non Programmers | Salesforce For Non Technicals
You can learn Salesforce without any programming language. You can plan Salesforce Administrator Certification which requires no coding skills. Watch this video to learn how.
Web to Case Functionality in Salesforce | All You Need to Know
This video discusses the functionality of Web to Case in Salesforce, which allows website users to submit inquiries or information that can be converted into…