Questions tagged [recentlyviewed]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
3
votes
1answer
883 views

Query RecentlyViewed return different result from Recent Item

I run this query to get RecentItem data, SELECT Id, Name FROM RecentlyViewed ORDER BY LastViewedDate DESC LIMIT 10 But I m login as same user,open SFDC Home in other tab and my customize Home in ...
1
vote
0answers
72 views

RecentlyViewed causes non-selective query error when run from a screen flow

I have a screen flow that calls an invocable apex method containing the query: List<RecentlyViewed> viewedRecords = [SELECT Id , Name , Type , LastViewedDate FROM RecentlyViewed WHERE ...
0
votes
1answer
56 views

Hide 'New' Button on Recently View from Opportunity Page

Is it possible to hide the New (Standard Record creation button) from the Recently view of the Opportunity page? Else is there any way we can customize the New button (Only Recently view not Other ...
1
vote
0answers
216 views

Can't fetch recently viewed list view information for custom objects

I am trying to fetch existing list views for a custom object, I can find 'Recently viewed' list filter in custom object home page or in its standard tab. But when I query it by SOQL SELECT id, Name, ...
0
votes
0answers
56 views

Assign RecentlyViewed SOQL query to List

I'm trying to query the recentlyviewed records for a user in a login flow. When I run the following query I receive this error: "Compile Error: Illegal assignment from List<RecentlyViewed> to ...
0
votes
0answers
30 views

RecentlyViewed not working for Account for portal user

recentlviewed not working for Account for portal user listRecent = [SELECT Id, Name,Type FROM RecentlyViewed WHERE type IN('Contact','Account','Opportunity','Lead') and LastViewedDate !=null ...
1
vote
1answer
229 views

ERROR on Recently Viewed: INVALID_TYPE: record type xxxxxx doesn't belong to xxObjectxxx

Recently switched over to Lightning from Classic. Got this error in testing but never able to replicate it. Assumed it was an issue during development but now a user is getting it in Production when ...
1
vote
1answer
27 views

Is it possible to get recordType from RecentlyViewed SOQL?

Is this possible? SELECT Name FROM RecentlyViewed WHERE Type = 'foo' and Type.RecordType.Name = 'bar' If yes, how should I go about it?
0
votes
1answer
954 views

Recently Viewed list filter for custom objects

Why salesforce does not show Recently Viewed List filter for Custom objects in Salesforce classic? Is there anyway we can create list filter for Recently View records. I cannot find LastViewedDate ...
2
votes
1answer
2k views

Show all the records instead of recently viewed records

On Clicking Look up field,it will show recently viewed records.But is it possible to show all the records which are satisfying the filter criteria,instead of showing recently viewed records.
5
votes
1answer
172 views

RecentlyViewed data leakage in unit tests

I have some code that queries RecentlyViewed and needed to be unit tested. I noticed a failure today because more records are turning up than expected. It turns out that if you query RecentlyViewed ...
2
votes
1answer
332 views

Is it possible to schedule a class to run as the system, instead of the current user?

Context: I have a class that is scheduled to run in an hourly basis, and it unfortunately updates a few dozens of records when it is run. As a result, I get these records on my "recent viewed" list, ...
1
vote
1answer
271 views

Entitlement lookup popup window not showing recently viewed anymore

Previously, when looking up an Entitlement from a Case, the recently viewed Entitlements would show up. Now, even users who have view all accounts and entitlements are not having this functionality. ...
2
votes
0answers
58 views

Recording When A Record Was Viewed / Visited?

I'm not finding any luck online. Does anyone know of a way to effectively (considering we're talking about Salesforce within a controlled Corporate environment) track when a record is VISITED and by ...
2
votes
1answer
841 views

Testing RecentlyViewed object records

I've got an Apex class with simple method returning recently viewed records using 'RecentlyViewed' object type. The issue is with inserting test data for unit tests because LastViewedDate field is not ...
3
votes
2answers
156 views

View override and Recent Items list

I noticed when I load a record for an object that has its View overridden with a Visualforce page, it does not put this record into the "Recently Viewed" list. Is there any way to put this record ...