odp.net

Is ODP.NET required for Oracle 11g Client?

﹥>﹥吖頭↗ 提交于 2019-11-29 04:21:24
I may be asking the wrong question here, I'm willing to change it if so. I have a project that is using the Microsoft.NET Oracle provider (our plan is to change to ODP but we haven't done so yet). I am trying to get this project to build on a windows 2008 (x64) build server. It builds just fine but our unit tests fail when they hit stuff on the Oracle database. I had initially installed the 32bit oracle 9i client which is what we currently use on our winxp dev boxes and the previous 2003 build server. But now this gets a message like: Attempt to load Oracle client libraries threw

How to configure DbContext to work with Oracle ODP.Net and EF CodeFirst?

泪湿孤枕 提交于 2019-11-29 02:32:34
I'm trying to work with EF CodeFirst under Oracle with ODP.net. This is my DbContext class: public class MyCEContext : DbContext { public DbSet<Person> Persons { get; set; } protected override void OnModelCreating(DbModelBuilder modelBuilder) { modelBuilder.Entity<Person>().ToTable("PERSONS","myce"); } public MyCEContext() : base(new OracleConnection( "Data Source=cebd; User ID=myce; Password=****;"), true) {} } Problem is that when I try to do something like this: MyCEContext context = new MyCEContext(); Person p = context.Persons.Find(1); I get this inner error: {"ORA-00942: table or view

How does fetching data from SQL Server to SqlDataReader work?

此生再无相见时 提交于 2019-11-29 02:19:12
问题 When I call this code: using (var connection = new SqlConnection(connectionString)) { var command = new SqlCommand("SELECT * FROM Table", connection); connection.Open(); using (var reader = command.ExecuteReader()) { while(reader.Read()) { // Do something here } } } what happens internally? How does this work on a network level? Will it make a new round trip to database for each call to Read or is there any batch read implemented internally? I'm asking because I just read that ODP.NET

EF + ODP.NET + CLOB = Value Cannot be Null - Parameter name: byteArray?

二次信任 提交于 2019-11-29 01:58:18
Our project recently updated to the newer Oracle.ManagedDataAccess DLL's (v 4.121.2.0) and this error has been cropping up intermittently. We've fixed it a few times without really knowing what we did to fix it. I'm fairly certain it's caused by CLOB fields being mapped to strings in Entity Framework, and then being selected in LINQ statements that pull entire entities instead of just a limited set of properties. Error: Value cannot be null. Parameter name: byteArray Stack Trace: at System.BitConverter.ToString(Byte[] value, Int32 startIndex, Int32 length) at OracleInternal.TTC.TTCLob

The provider is not compatible with the version of Oracle client error when using Oracle.DataClient

穿精又带淫゛_ 提交于 2019-11-28 23:21:37
I'm using Visual Studio 2008 Express Edition, and I'm trying my hand in developing a small application using Oracle.DataClient. I'm getting the above mentioned error, when trying to connect to the database in the target system. I've added a reference to Oracle ODP.net provider for Oracle 10gR2, and in the target machine I have a copy of Oracle 10gR2 database installed. Despite this, I'm getting the error. Before posting this, I read this post at SO, and I have installed the instant client, the error persists. Below is the full error stack. ************** Exception Text ************** System

Entity Framework 6 (5) connection to Oracle

一世执手 提交于 2019-11-28 21:43:16
I am attempting to write a Data Access library for our suite of applications that use Oracle in .net. We currently use NHibernate and are thinking of migrating away as it appears to not be supported all that well. I am working with Visual Studio 2013 and we have already constructed our Oracle Database. We don't have writes to update it (that is the domain of the db guys). So that will not be part of any calculation on our end. The client on the server is 32 bit, so we are going to stick with that for now. It is already GAC'd in there, and no need to change it. So we have the 32 bit client on

In WiX how do I test for the existence of a registry key (not value) for Oracle ODP.Net

╄→гoц情女王★ 提交于 2019-11-28 21:17:23
More specifically I want to test whether Oracle ODP.Net is installed on a machine. I want to do this by testing for the HKLM\SOFTWARE\ORACLE\ODP.NET registry key. The actual values used by ODP.Net are stored in HKLM\SOFTWARE\ORACLE\ODP.NET\2.111.6.20 however I assume that this lower level key's name will change as updates are released by Oracle. I have tried the following which fails, possibly because the (Default) value doesn't really exist or possibly because it is null (I'm not sure exactly how it's represented in the registry). <Property Id="ORACLE_ODPNET"> <RegistrySearch Id="ODPNET

ODP.NET Oracle.ManagedDataAcess random ORA-12570 errors

倖福魔咒の 提交于 2019-11-28 20:36:15
I'm trying to migrate to Oracle.ManagedDataAcess from unmanaged version and receiving randoms ORA-12570 TNS:packet reader failure. I don't know why this error starts, but once it starts, every subsequent request gives the same error for about 10-30 minutes, then it works again for another 10-30 minutes and so on. So it is a random of subsequent failures for some time then subsequent success Already tried a lot of things, to resume: The environment: Oracle.ManagedDataAcess version 12.1.2400 (4.121.2.20150926) (nuget) (no gac reference installed on server that could override the bin version)

Oracle.DataAccess.Client.OracleException ORA-03135: connection lost contact

无人久伴 提交于 2019-11-28 18:59:38
I have a .Net service that connects to an Oracle database on every request. It works fine at the beginning, but after some number of requests I start getting: Oracle.DataAccess.Client.OracleException ORA-03135: connection lost contact at Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object src, String procedure) at Oracle.DataAccess.Client.OracleException.HandleError(Int32 errCode, OracleConnection conn, String procedure, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object src) at Oracle

Oracle number to C# decimal

有些话、适合烂在心里 提交于 2019-11-28 13:26:49
I know there are several threads and posts regarding this issue in the internet and I've read them (not every article, I have to admit) but none of them did fully satisfy me. My situation: I'm using ODP.net (dll version 2.111.6.0) to access the Oracle DB (version 10 + 11) and a DataReader to retrieve the data (.NET 3.5, C#). Using this code results in a ' System.OverflowException (Arithmetic operation resulted in an overflow.) ' decimal.TryParse(oraReader.GetOracleDecimal(0).Value.ToString(), NumberStyles.Any, null, out parsedOraDecimal) and this one results in a value of ' 3