Skip to Main Content

ODP.NET

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Invalid cast exception when using XDocument valueConverter and EFCoreSecondLevelCacheInterceptor

User_WPD5LMar 18 2021

Hi,
We are using an oracle 11 database with the ODP for EF Core 5 (5.21.1) and since we did the upgrade from EF Core 3.1, we are encountering an issue when we try to create a query on an entity with a valueConverter (XDocument to string) in combination with EFCoreSecondLevelCacheInterceptor (2.4.1)
image.pngOn entities without this valueConverter, the query and caching is working correctly.
Both the EFTableRowsDataReader and OracleDataReader inherit from the same DbDataReader class, but the casting is not working.
Is this a known issue that will be fixed in an upcoming version?

Comments

Alex Keh-Oracle

Looks like it's a known issue. You can try the recommended steps in the thread to make sure you have updated all your dependencies.

User_2SBJ9

@bjarne-callewaert do you get any successful answer to fix this issue ? I would like to use the same cache library however I'm getting the same error

1 - 2

Post Details

Added on Mar 18 2021
2 comments
195 views