odp.net

ODP.NET Managed library does resolve alias, but 32-bit library does

谁说胖子不能爱 提交于 2019-11-28 02:24:46
I have 32-bit drivers installed on my box (they were installed and configured by some DBAs) I wrote a simple script to test the drivers which pretty much is as follows using (DataTable table = new DataTable()) { using (OracleConnection connection = new OracleConnection()) { connection.ConnectionString = "Data Source=alias;User id=user;Password=password"; connection.Open(); using (OracleCommand command = connection.CreateCommand()) { command.CommandType = CommandType.Text; command.CommandText = "SELECT * FROM DUAL"; table.Load(command.ExecuteReader()); } } } When I compile this application as

ORACLE and Entity Framework. Error:the specified store provider cannot be found in the configuration or is not valid

假如想象 提交于 2019-11-28 01:40:31
问题 In my project I am using oracle and entity framework together.Both of my machines my developer machine win7 and my server win2008r2 I installed oracle beta entity framework and .net 4.0 framework. However my projects works on local machine and does not work on server giving the error : the specified store provider cannot be found in the configuration or is not valid SystemArgumentException unable to find the requested .net Framework data provider ... Anyone can help me ? 回答1: In the

Oracle.DataAccess not available for selection in Visual Studio 2013

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-28 01:23:37
I've recently set up a Windows 8.1 64 Bit Machine with Visual Studio 2013 (probably 32 bit, at least it installed itself at Program Files (x86)). I've also installed the Oracle 11.2.0.1 64 Bit Client with Oracle Data Provider for .NET. When I do gacutil /l | findstr Oracle.DataAccess, I get four entries, including the following: Oracle.DataAccess, Version=2.112.1.0, ..., processorArchitecture=AMD64 However, I cannot find Oracle.DataAccess in any of the lists when trying to add an assembly (Oracle.Web is present under Assemblies->Extensions, though). Do I have to install the 32 bit Oracle

ODP.Net Managed Driver - ORA-12704: character set mismatch in generated code

本小妞迷上赌 提交于 2019-11-28 01:06:56
问题 I am currently using the Oracle Managed Driver (v12.1.2400) as my Entity Framework driver, and am currently seeing a ORA-12704: character set mismatch error during execution. The LINQ->SQL code I am using is as follows: from c in CUSTOMER.AsNoTracking() where c.ACCOUNT.Contains("DE") && c.DELETED == "N" orderby (c.FORENAME + c.SURNAME) select new { c.ACCOUNT, c.FORENAME, c.SURNAME}) and this is creating the following SQL: SELECT "Project1"."C2" AS "C1", "Project1"."ACCOUNT" AS "ACCOUNT",

ORA-12504: TNS:listener was not given the SERVICE_NAME in CONNECT_DATA

耗尽温柔 提交于 2019-11-28 00:21:34
问题 I'm trying to connect my local Oracle 11g database using server explorer in Visual Studio 2010. I tried to setup everything as per instruction, but I'm still getting an ORA-12504 error. Here is the error: Here is my tnsnames.ora contents: # tnsnames.ora Network Configuration File: C:\app\rsahi\product\11.2.0\dbhome_1\network\admin\tnsnames.ora # Generated by Oracle configuration tools. VENUS = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = SPRPRG020)(PORT = 1521)) (CONNECT_DATA = (SERVER =

How to return a RefCursor from Oracle function?

情到浓时终转凉″ 提交于 2019-11-27 23:56:14
I am trying to execute a user-defined Oracle function that returns a RefCursor using ODP.NET. Here is the function: CREATE OR REPLACE FUNCTION PKG.FUNC_TEST (ID IN TABLE.ID%type) RETURN SYS_REFCURSOR AS REF_TEST SYS_REFCURSOR; BEGIN OPEN REF_TEST FOR SELECT * FROM TABLE; RETURN REF_TEST; END; / I can call this function in Toad (select func_test(7) from dual) and get back a CURSOR. But I need to get the cursor using C# and ODP.NET to fill a DataSet, but I keep getting a NullReferenceException - "Object reference not set to an instance of an object". Here is what I have for that:

ODP.NET Oracle.ManagedDataAccess causes ORA-12537 network session end of file

孤人 提交于 2019-11-27 22:21:41
Overview I want to replace Oracle.DataAccess with Orcale. Managed DataAccess, but opening a connection with the latter throws an ORA-12537 network session end of file exception. Exception message / stack trace {OracleInternal.Network.NetworkException (0x000030F9): ORA-12537 : Netzwerksession: Dateiende at OracleInternal.Network.ReaderStream.Read(OraBuf OB) at OracleInternal.TTC.OraBufReader.GetDataFromNetwork() at OracleInternal.TTC.OraBufReader.Read(Boolean bIgnoreData) at OracleInternal.TTC.MarshallingEngine.UnmarshalUB1(Boolean bIgnoreData) at OracleInternal.TTC.TTCProtocolNegotiation

Is ODP.NET required for Oracle 11g Client?

孤街醉人 提交于 2019-11-27 22:21:35
问题 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

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

大憨熊 提交于 2019-11-27 20:25:43
问题 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,

Code for calling a function in a package from C# and ODP.NET

给你一囗甜甜゛ 提交于 2019-11-27 19:31:07
I've tried to write C# code with ODP.NET to call a function in a package. I'm getting the two errors below: ORA-06550: line 1, column 7: PLS-00306: wrong number or types of arguments in call to INSERT_FUNC' ORA-06550: line 1, column 7: PL/SQL: Statement ignored ORA-06550: line 1, column 7: PLS-00221: 'INSERT_FUNC' is not a procedure or is undefined ORA-06550: line 1, column 7: PL/SQL: Statement ignored My OracleCommand is set up as: cmd.CommandText = "PKG_NAME.INSERT_FUNC"; cmd.CommandType = CommandType.StoredProcedure; How should I pass parameters to the function below? Do I need to add a