Contact Us

If you still have questions or prefer to get help directly from an agent, please submit a request.
We’ll get back to you as soon as possible.

Please fill out the contact form below and we will reply as soon as possible.

  • Contact Us
  • Home
  • Orenda Grids Help V4.0
  • V4

How to implement Virtual Fields in XRL

Learn how to effectively implement virtual fields in your XRL database to streamline data processing and enhance reporting capabilities.

Written by Akanksha Shukla

Updated at December 3rd, 2025

Contact Us

If you still have questions or prefer to get help directly from an agent, please submit a request.
We’ll get back to you as soon as possible.

Please fill out the contact form below and we will reply as soon as possible.

  • Orenda Grids Help V4.0
    V4
  • Partner Quoting Workspace (PqW)
  • Partner Renewal Workspace (PrW)
  • Extended Related List- XRL
    Getting Started With XRL XRL V4
+ More
  • Orenda Grids Help V4.0

    • V4

      •  Introduction to Orenda Grids
      •  Installation and Setup Guide- Orenda Grids
      •  Basic Configuration of Extended Related List Component in Orenda Grids
      •  Advanced Configuration of Extended Related List Component in Orenda Grids
      •  Understanding the Extended Related List Interface in Orenda Grids
      •  How to Create Multiple Data Views using Orenda Grids XRL
      •  How to Share and Delete XRL Views
      •  How to Enable Comparison Interface in Data Views
      •  How to implement Virtual Fields in XRL
      •  How to Customize Data Representation in XRL for efficient Lookup, Browsing and Actions
      •  How to Enhance Data Representation in XRL With Advanced Row Settings
      •  How to Create Salesforce Data Views With Unlimited Records
      •  How to add and filter data through Lookup fields in XRL
      •  How to Enhance Data Presentation in XRL with Advanced Column Settings
      •  How to Customize Action Settings in XRL
      •  How to Apply Server-side Filters in XRL
      •  How to Apply Client-side Filters and Sort in XRL
      •  How To Create Salesforce Data View With Indirect Related Lists In XRL
      •  How to customize actions using Advanced settings in XRL
      •  How to enable dynamic server side filtering in XRL views
      •  How to Edit/Bulk Edit Fields in XRL
  • Partner Quoting Workspace (PqW)

  • Partner Renewal Workspace (PrW)

  • Extended Related List- XRL

Introduction

The Add Virtual Field functionality in Orenda Grids allows users to dynamically create custom fields in a list view for specific use cases without modifying the underlying Salesforce object. These virtual fields enable calculations and data representations that are not stored in the database but are necessary for real-time analysis. This feature supports operations like sorting and filtering, making it as versatile as standard fields.

Virtual fields are created through the Configure dialog in Extended Related Lists (XRL) and are available only within the specific list view they are defined for.

Key Benefits of Virtual Fields Feature

  • Perform on-the-fly calculations without altering the database schema.
  • Extend list view capabilities to represent derived data for enhanced insights.
  • Use advanced formatting and calculations through the formatter callback.
  • Enable dynamic operations like sorting and filtering on calculated fields.

 

Prerequisite

Make sure that you log in to your Salesforce account, install, and configure Orenda Grids XRL. Refer to the links below for more detailed instructions. 

  • Installation and Setup
  • Basic configuration
  • Advanced configuration

Though virtual fields can be added in Grid by any user with XRL license, only a Power user can enable the field data using Advanced section in Field Settings.

 

Limitations in Salesforce Views

While Salesforce provides robust data management capabilities, standard views have certain limitations that Orenda Grids’ Add Virtual Field feature addresses following limitations

1.  Creating a new field in Salesforce requires administrative access and permanent schema changes. Standard users cannot add fields dynamically for temporary or specific use cases.

2. Salesforce does not allow dynamic field creation within standard list views or related lists. Fields must be predefined and tied to the object schema. Thus, users can't perform ad hoc calculations or create derived fields.

 

Procedure

Here, we will take an example use case: Calculating Total Price in a Custom Object to show how to create and use a virtual field in XRL.

Suppose your custom object contains two fields: List Price and Quantity, but no field for Total Price (calculated as List Price * Quantity). Instead of creating a new field in Salesforce, you can use a virtual field to calculate and display the Total Price for each record dynamically.

Follow these steps to add a virtual field:

Step 1: Click on the Configure button at XRL home. 

Step 2: Click on the Add Virtual Field tab within Field Selection Tab.

Step 3: Name the virtual field and put an api name as required and click on Save Virtual Field button.

Step 4: Now, proceed with Field Settings on the configuration wizard and select Total_Price field from the dropdown.

Step 5: Select Advanced Section as shown below and enter the code snippet mentioned below.

 

{ 

“formatter”: function(scope,libs,row,col,val){ 

return row.listPrice__c * row.quantity; 

} 

Step 6: Click on Save to save the current view with update or Save As to create a new view.

 

Results

The following procedure results in addition if a virtual field named Total_Price having value as per the conditions set in code. 

By leveraging virtual fields, Salesforce users can extend the functionality of their list views to display calculated or derived data directly within the platform. This eliminates the need for manual data exports or schema changes, ensuring a streamlined and efficient workflow.

xrl implementation virtual fields

Was this article helpful?

Yes
No
Give feedback about this article
In this article
  • Introduction
  • Key Benefits of Virtual Fields Feature
  • Limitations in Salesforce Views
  • Procedure
  • Results

Related Articles

  • How to Enhance Data Presentation in XRL with Advanced Column Settings
  • Understanding the Extended Related List Interface in Orenda Grids
  • Advanced Configuration of Extended Related List Component in Orenda Grids
  • How To Create Salesforce Data View With Indirect Related Lists In XRL
Orenda Logo Salesforce Logo

Salesforce™ Force.com™ and other trademarks are trademarks of salesforce.com, inc. and are used here with permission.

Company

  • About
  • Why Orenda
  • Contact

Solutions

  • Asset Management
  • CPQ Accelerator
  • Multi Level History Tracking
  • Order Management

Others

  • FAQ
  • Privacy Policy
  • Glossary

Copyright 2024. All rights are reserved

  • Orenda
  • sales@orendahq.com

Knowledge Base Software powered by Helpjuice

Expand