Questions tagged [pricebookentry]

Represents a product entry (an association between a Pricebook2 and Product2) in a price book.

Filter by
Sorted by
Tagged with
0
votes
0answers
17 views

Clone with related -- PricebookEntryId (pricebook entry is in a different pricebook than the one assigned to the opportunity): [PricebookEntryId]

I am getting this issue PricebookEntryId (pricebook entry is in a different pricebook than the one assigned to the opportunity): [PricebookEntryId] when ever I tried to clone an opportunity with ...
0
votes
0answers
14 views

Price Book Entry History Report

Is there no report capability to see the Price Book Entry History? I need to be able to report on what date a certain Product changed price in a certain Price Book and what it changed FROM/TO. I also ...
0
votes
0answers
16 views

Price Book with 2 prices for same Product [duplicate]

The following query returns 2 rows for me SELECT CurrencyIsoCode,Id,IsActive,IsArchived,IsDeleted,Name,Pricebook2Id,Product2Id,ProductCode,UnitPrice,UseStandardPrice FROM PricebookEntry where product2....
1
vote
0answers
27 views

DataLoader batch job failing with PricebookEntry upsert

I have an issue with our PRICE BOOK ENTRY Upsert using the DataLoader batch bulk job. We have External IDs in our PRICE BOOK and PRODUCT objects that we use when Upserting to our PRICE BOOK ENTRY ...
1
vote
1answer
43 views

BulkAPI 2.0 Import PricebookEntries via Postman getting this error:STANDARD_PRICE_NOT_DEFINED:Before creating a custom price, create a standard price

I have setup the Postman requests to talk to the salesforce BulkAPI 2.0 because the dataLoader doesn't work (MacBook M1). The import of the pricebookentries fail at a point because when I import the ...
0
votes
2answers
96 views

Using Custom Price Book Entry Object

I am developing the custom aura component for adding products to the opportunity for achieving client requirements. For this, I have created a custom price book entry object but while creating the ...
0
votes
0answers
22 views

SFDX. Import PricebookEntry2 to standard Pricebook2

I want to import price book entries and relate them to standard price book on scratch org. I'm using sfdx force:data:tree:import. But I can't relate my new price book entries with the already existing ...
0
votes
1answer
524 views

FIELD_INTEGRITY_EXCEPTION, Price Book Entry ID: id value of incorrect type: [PricebookEntryId]

Hi all I have a test method which it creates data (makeData) for the following test methods. But I'm getting this message over and over again. System.DmlException: Insert failed. First exception on ...
0
votes
0answers
56 views

Creating opportunity line from SalesforceSharp

I am using SalesforceSharp to create an Opportunity. The header is working OK, I have ensured that the CurrencyIsoCode and PriceBook2Id fields are set. When trying to create the Opportunity Line Item,...
0
votes
1answer
40 views

STANDARD_PRICE_NOT_DEFINED, No standard price defined for this product

I checked the other answers about this topic but I have no clear result. I think Id pricebookId = Test.getStandardPricebookId(); is use to get a standardPrice before insertion of PricebookEntry in a ...
0
votes
2answers
87 views

Update both Pricebook2 and PricebookEntry objects using just one for loop

Having the next code: for (WrapperTest pb : pbs_lst) { Pricebook2 newPB2 = new Pricebook2(); PricebookEntry newPBE = ...
0
votes
0answers
18 views

Want filtered Products while trying to add Order products in Order's Related List

I am using Order and Order Products to generate Invoices for customers. Issue is the Products(PriceBook Entries) available are different on the basis of different Location, and while adding these ...
0
votes
0answers
53 views

Trigger after Insert Order Item - PriceBook Entry

I have a trigger After insert on OrderItem. This Trigger should insert automatically dependents product in the order . My Problem is that I don't understand how I can efficiently set the ...
0
votes
1answer
89 views

Are Pricebook and Pricebookentries available in Service cloud? [closed]

Please let me know if these objects are available in service cloud.
0
votes
0answers
27 views

Add Product on Order - PriceBookEntry not active

For some sale processes, I need to add specific items on Order through code that I don't allow users to Add from the add Product screen. To do that I simply disactivated the PriceBookEntry of this ...
0
votes
1answer
412 views

Insert PriceBookEntry using Product2 External Id field

I am developing an external application which will insert & update products and their pricebook entries into Salesforce system. In order to avoid maintaining the Salesforce ProductId in my ...
3
votes
1answer
2k views

Get custom Picklist value in LWC without Record Type

I have created a custom Picklist in PricebookEntry and trying to get the Picklist values in LWC. All the solutions I found needs to pass the RecordTypeId to get the list. @wire(...
0
votes
1answer
232 views

How to display Product fields and it's pricebookentries in a single datatable?

I need to dynamically put products and the products' pricebookentries in a single row in a datatable. If I add a pricebook, a new column and it's prices should also be displayed. I could do this for ...
-1
votes
1answer
44 views

string.isempty doesn't appear to work when trying to retrieve price list Name

it appears my if statement with String.isEmpty doesn't seem to be working. What i want it to do is check if a price list entry doesn't exist it creates a new one, and if it does it updates that one. ...
0
votes
1answer
44 views

Not Able To Update Price Entries

I am trying to insert products, then those products then create price entries if they don't already exist but if they do exist they update the previous price entry based on the name of the product ...
0
votes
0answers
83 views

Use Database.upsert with external id field is not working on PricebookEntry object

I need help to do a DML operation with external id field. I am using the below syntax, but it is throwing an error Schema.SObjectField f = PricebookEntry.Fields.Product_Code__c; Database.UpsertResult[...
3
votes
1answer
195 views

Change the label of a standard field of PriceBookEntry object

Is it possible to change the label of a field (in my case I'd like to change the label of the UnitPrice field) of the PriceBookEntry standard object ? In the setup -> tabs and labels, I don't see ...
0
votes
1answer
99 views

Load PricebookEntry in empty Scratchorg with Cumulusci

When generating a .yml file with generate_dataset_mapping with cumulusci it resolves in following code(sample): Insert Product2: sf_object: Product2 table: Product2 fields: Id: sf_id ...
0
votes
1answer
122 views

How to restore or undelete PricebookEntry records

Is it possible to undelete/restore a deleted PricebookEntry record? I am not referring to restoring a Price Book or Product record but hitting the delete button on an entry record itself, then ...
0
votes
1answer
126 views

Order Pricebook2Id to manage with multiple Order Product Pricebooks

Scenario: There are multiple Order Products with different Pricebook(Year wise Pricebook) to be added on Order Object. But, on Order Object we can only set a single Pricebook Id. Can anyone please ...
1
vote
1answer
137 views

Error when I try to create OrderItem records Insert failed. INVALID_CROSS_REFERENCE_KEY

I'm trying to create a visualforce page where a user can create multiple OrderItem records at the same time. The error that I get is OrderItem records Insert failed. First exception on row 0; ...
-1
votes
1answer
505 views

Add a picklist value to Global Value Set in test class

I am working on test class that inserts an Opportunity with the opportunity products using the correct price book/price book entry. The OpportunityLineItem has a ProductSelected__c picklist field. We ...
0
votes
1answer
869 views

Different currencies in PricebookEntry throwing exception FIELD_INTEGRITY_EXCEPTION, PricebookEntryId (must have the same currency as the order)

I wrote a trigger which converts a Quote to Order on changing Status to a particular value. This Quote has QuoteLineItems, hence, they should converted to corresponding OrderItems. Now when the ...
0
votes
2answers
1k views

Pricebook and PricebookEntries with different currencies

Can Pricebook and its PricebookEntries have different currencies? So, if I create a Pricebook with currency USD and its PricebookEntries with multiple currency like USD, GBP, AUD, etc., is this ...
2
votes
1answer
971 views

PriceBookEntry required field missing when creating QuoteLineItems

I am kind of new to CPQ and have been trying to create a Quote Line Item with no success. Opportunity OpportunityOne = [SELECT Id, PriceBook2Id FROM Opportunity WHERE Id='...
0
votes
0answers
318 views

Pricebook2Id not populating in opportunity when default price book is already present

I have applied a default pricebook to a set of users. When I try to add products to that opportunity the pricebook already shows that it is selected at the product selection screen but still ...
0
votes
1answer
127 views

I am unable to query pricebook entry. (Internal Salesforce Error)

I am making a lightning component for a user to create a quote + line items quick and easy. However the apex function that is meant to query the pricebook entry and its Id for each line item is ...
1
vote
0answers
424 views

Selecting the Opportunity Price Book

I'm still fairly new to Salesforce Apex and trying to figure out how to select a price book from the opportunity. The reason being I have a trigger which adds in a product when the opportunity is ...
1
vote
1answer
824 views

Is it possible to update Order Product on Draft Order?

We are trying to utilize the Order object, but we're finding that if we create an Order Product, we are unable to change the product (i.e. essentially the Pricebook entry), even if we're in a Draft ...
0
votes
1answer
112 views

PricebookEntry Conflict Error not matching existing products

I am getting an error message on a trigger that was working until recently. The issue arises on a trigger that inserts an OpportunityLineItem on an Opportunity. Here is the error: Insert failed. ...
1
vote
2answers
1k views

FIELD_INTEGRITY_EXCEPTION when creating Price Book Entry from flow

I have created a flow that creates a pricebook entry for new products (based on a custom field on the Product object), however when I debug the flow it comes up with the following quite generic error: ...
1
vote
1answer
115 views

Failure when inserting records via dataloader, however anonymous apex inserts fine

I'm getting the following error when running dataloader (inserting new quotelineitems), however an identifcal anonymous apex works fine - any thoughts? Error: The price book entry is in a different ...
0
votes
1answer
368 views

Trying to do an SOQL Query for all product names and their Price books

I Have a Salesforce Org where there are almost 1000 products and 51 Price books, I want to know a query where I can get each product and the price books they belong to. Any help is much appreciated!
0
votes
1answer
341 views

How to prefill UnitPrice on Order Products

I want my Order Product price to prefill based on the price defined on the Pricebook Entry. I swear I've seen this work in the past, but I can't figure out why this time I keep getting an empty field ...
5
votes
1answer
1k views

In which sequence should I be creating/inserting order/orderItem/pricebookEntry/product2?

I'm on the advanced apex super badge step 7, and before this I thought I had a good understanding of order/orderItem/pricebookEntry/product2/pricebook2 objects. However, upon creating my own ...
3
votes
1answer
2k views

Find all Product2 records that do NOT have a PricebookEntry in the Standard Price Book

We have come to find that we have a small amount of products that have Product2 records, but no PricebookEntry for them. I'm trying to query for just those products, but I am having trouble with the ...
0
votes
1answer
496 views

Deep Cloning a Product - Clone Standard Price and Custom Prices

I have created a Record Detail button to clone a Product's detail, a related list called Bill of Materials, and both the Standard PB Entry, and any Custom PB Entries. If I remove the Custom PB Entry ...
1
vote
1answer
2k views

Automatically add a Standard Price Book Entry after creating product

I am successfully importing a CSV of products and creating Product objects in Salesforce. I'd like to be able to automatically (or even via CSV update) create Standard prices for those objects, but ...
1
vote
1answer
582 views

Make Price Book Entry object's Product Code field Read/Write

I'd like to automatically create Standard Price Book entries for new products using dataloader.io. I am successfully creating the new products, using the Product Code as the ID. But when I go to ...
1
vote
1answer
721 views

Can I show the standard price on the product layout page?

I know I can click the Related Tab and drill into the Standard Price Book to see it, but it would sure be nice to just show it on the product page. Is this possible?
1
vote
2answers
1k views

FIELD_INTEGRITY_EXCEPTION, This price definition already exists in this price book

My requirement is to take any pricebook entry made in the standard pricebook and replicate/update it in a second price book. With the code below I keep getting the error FIELD_INTEGRITY_EXCEPTION, ...
-1
votes
2answers
480 views

SOQL Query on PricebookEntry returning no rows

I'm trying to create a queueable apex class which will update the unit prices of all Products (on all Pricebooks) based on newly updated exchange rates. I'm able to successfully query on ...
3
votes
1answer
201 views

In Pricebook Entry validation rule I am not able to access the Pricebook fields

I am trying to create validation rule under Pricebook entry object. In that I am not able to access the Pricebook field, we have standard lookup "Pricebook" field in Pricebook Entry.
0
votes
2answers
2k views

Test Classes failing due to default custom pricebook

Our admins developed and activated a process builder in Production to set a default custom pricebook on opportunity during the opportunity creation process. Due to this, several of our test classes ...
1
vote
0answers
68 views

Timeout Error when cloning a pricebook

I am getting a timeout error when cloning my Standard pricebook. Any known limits (as to the number of product or pricebook entry records)?