1、将.csproj文件
<TargetFramework>net5.0</TargetFramework>
2、连接oracle,open时报错:The type initializer for 'OracleInternal.ServiceObjects.OracleConnectionImpl' threw an exception.
需要在.csproj文件添加:<EnableUnsafeBinaryFormatterSerialization>true</EnableUnsafeBinaryFormatterSerialization>