Blog Layout

Which Products are not on any Opportunity?

Mike Arthur • Feb 24, 2017

Reports can't answer this but Workbench can

Knowing which of your products have never been added to an Opportunity is a good thing to know. Unfortunately, you can't get that answer with Reports, but it's easy to find out using Workbench.

You need to be on Enterprise Edition or higher, as Professional Edition and below don't have access to the API.

- go to https://workbench.developerforce.com
- click 'agree to terms' and login
- Select 'SOQL Query' in 'Jump To' picklist, leave 'Object' blank, click 'Select'
- In the 'Enter or modify a SOQL query below' box paste this
select name, productcode, id from product2 where id not in (select product2id from opportunitylineitem)
Click 'Query'
- This is the list of products that are gathering dust (good description @SteveMo :-) ).
- You can copy the results to paste somewhere else
- Copy the url showing in the address bar and save it somewhere. Just paste it back into browser at some later point and it will run the same query.

You can paste the same query into the Developer Console but the results are easier to copy and you can return to the query by revisiting the url when you use the Workbench option.

My Blog of Salesforce Stuff

by Mike Arthur 16 Oct, 2021
'XHR Failed' error when trying to install VS Code extension
by Mike Arthur 09 Jun, 2020
What is $A (dollar A) in Lightning Aura component framework? Is it a global variable? Where are the docs for $A?
by Mike Arthur 08 May, 2020
Authorise a Salesforce Connected App using OAuth 2.0 JWT Bearer Flow
by Mike Arthur 26 Apr, 2020
REST API Connection to Salesforce Connected App Using OAuth 2.0 Authentication from Postman
by Mike Arthur 23 Mar, 2020
How to create a Lightning tab menu with dropdown sub-menu
by Mike Arthur 27 Nov, 2018
How to show a month by month trend chart with multiple years on same chart
by Mike Arthur 06 Nov, 2018
What to do if you receive emails about expiring certificates
22 Aug, 2018
Process json strings when working with integrations
by Mike Arthur 22 Aug, 2018
If you're switching email accounts you can copy appointments from one calendar to the other
by Mike Arthur 22 Aug, 2018
When you search in Outlook 2016, how do you see in which folder you filed an email in the results?
More posts
Share by: