LocalView<TEntity>.FindEntryUntyped(IEnumerable<Object>) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Finds an EntityEntry<TEntity> for the entity with the given primary key values in the change tracker, if it is
being tracked. null
is returned if no entity with the given key values is being tracked.
This method never queries the database.
public virtual Microsoft.EntityFrameworkCore.ChangeTracking.EntityEntry<TEntity>? FindEntryUntyped (System.Collections.Generic.IEnumerable<object?> keyValues);
abstract member FindEntryUntyped : seq<obj> -> Microsoft.EntityFrameworkCore.ChangeTracking.EntityEntry<'Entity (requires 'Entity : null)>
override this.FindEntryUntyped : seq<obj> -> Microsoft.EntityFrameworkCore.ChangeTracking.EntityEntry<'Entity (requires 'Entity : null)>
Public Overridable Function FindEntryUntyped (keyValues As IEnumerable(Of Object)) As EntityEntry(Of TEntity)
Parameters
- keyValues
- IEnumerable<Object>
The values of the primary key for the entity to be found.
Returns
An entry for the entity found, or null
.
Remarks
By default, accessing Local will call DetectChanges() to ensure that all entities searched and returned are up-to-date. Calling this method will not result in another call to DetectChanges(). Since this method is commonly used for fast lookups, consider reusing the Local object for multiple lookups and/or disabling automatic detecting of changes using AutoDetectChangesEnabled.
See EF Core change tracking for more information and examples.
Applies to
Entity Framework
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for