This article explains why custom field values entered in the Revenue Cloud Transaction Line Editor (TLE) or Sales Transaction Line Editor (STLE) revert to zero or do not persist after save, and how to resolve the issue. Customers describe this as: "manually entering a discount value (e.g., 23%) in the Quote Line Editor causes the value to revert back to 0 upon save", "trying to update pricing procedure to include new custom currency field but from the line editor the value is not staying", and "Formula Based Pricing not working properly — working in logs level but not working at UI level in Line Transaction Editor". The save may complete silently with the field reset, or it may surface the error "Resolve error: Multiple SOQLs provided for attributes in design time. Hydration Ids - <ids>". Two trigger conditions cause this behaviour: (1) a custom field has been added to Quote Line Item [QuoteLineItem] or Order Product [OrderItem] but has not been added as an INPUT/OUTPUT attribute on the active extended SalesTransactionContext context definition and mapped to the sObject field; or (2) the active pricing procedure recalculates and overwrites the field during repricing because no Assignment or Formula Based Pricing element preserves the user-entered value. Applies to Revenue Cloud (Core) on Enterprise, Unlimited, and Developer editions where Transaction Management and Salesforce Pricing are enabled (Summer '24 and later). Required permission sets: Manage Revenue Cloud, Price and Tax Calculation for Quoting, Salesforce Pricing Admin, Salesforce Pricing Design Time User, and Context Service Admin.
Resolve the issue by ensuring the custom field is exposed as an attribute on the active context definition and is preserved by the pricing procedure.
Cause 1: Custom field is not mapped on the extended SalesTransactionContext context definition
1. Identify the active context definition. From Setup, enter Revenue Settings in the Quick Find box and select Revenue Settings. Note the context definition name listed under Set Up Salesforce Pricing.
2. From Setup, enter Context Service in the Quick Find box and select Context Definitions.
3. Open the active custom context definition that extends SalesTransactionContext. If none exists, click Extend on SalesTransactionContext, name the new definition, and save.
4. Deactivate the context definition before editing. Click the version number, then click Deactivate.
5. On the Custom Definitions tab, select your context definition and click Edit.
6. On the SalesTransactionItem node, click Add Attribute. Enter the attribute name to match your custom field (for example, DiscountPercent__c, AmountAfterDiscount__c). Set Data Type to the matching type (NUMBER, STRING, or BOOLEAN) and Direction to INPUT OUTPUT. Save.
7. On the Map Data tab, select QuoteEntitiesMapping and click Edit SObject Mapping. Map the new attribute to the corresponding field on Quote Line Item [QuoteLineItem] (for example, DiscountPercent__c → QuoteLineItem.DiscountPercent__c). Click Map and Save.
8. Repeat step 7 for OrderEntitiesMapping, mapping the attribute to the equivalent field on Order Product [OrderItem].
9. Activate the context definition by clicking Activate on the new version.
Cause 2: Pricing procedure overwrites the user-entered value during repricing
1. From Setup, enter Revenue Settings and note the Pricing Procedure Name under Set Up Salesforce Pricing.
2. From the App Launcher, open the Price Management app and find the matching Pricing Procedure.
3. Click the active Version Number and click Deactivate.
4. Click Save As to create a new version, or edit the deactivated version.
5. Add an Assignment element immediately after the Pricing Setting element. Set the Input Variable to the new attribute (for example, DiscountPercent__c) and the Output Variable to the same attribute, so the user-entered value is read into the calculation context before any subsequent element can overwrite it.
6. If the field must drive a calculation (for example, compute Net Unit Price from a custom AmountAfterDiscount__c), add a Formula Based Pricing element after the Assignment. Enter the formula (for example, VALUE(AttributeValue) * NetUnitPrice) and select the correct Output Variable (for example, NetUnitPrice).
7. Confirm no later element in the procedure writes back to the custom attribute unless intended. Remove or guard any element that resets the attribute to zero.
8. Save and Activate the new pricing procedure version. From Setup, open Revenue Settings and confirm the active version under Set Up Salesforce Pricing matches.
Final verification
1. Open a quote and add a product via Browse Catalogs or the Add Product search field.
2. In the Transaction Line Editor, click the custom field cell, enter a non-zero value (for example, 23 for a percent field), and click Save.
3. Click Reprice All to force a full repricing pass.
4. Confirm the issue is resolved by reopening the quote line and verifying the custom field retains the entered value, the price waterfall (hover over Net Unit Price) reflects the value, and no "Multiple SOQLs provided for attributes in design time" error appears.
005385064

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.