tnsnames

Oracle.ManagedDataAccess not resolving alias in connection string

拥有回忆 提交于 2019-12-02 06:02:45
I'm getting the following error while trying to connect to an Oracle database from a new VB.NET 4.5 application "ORA-00351: Network Library: Name-Value premature end of string" It seems like OracleConnection is not resolving the alias I am putting in my connection string Me.sCNX = "Data Source=" & sDSN & ";User ID=" & sUSER & ";Password=" & sPWD & ";Enlist=false;Pooling=False;" sDSN being the said alias I have to put the tnsnames.ora file in a custom folder, so I tried to add the environment variable TNS_ADMIN to the right directory, didn't work much I tried to put a setting line in app.config

Connection to Oracle via TNS is not working

我是研究僧i 提交于 2019-12-01 08:43:58
I have a Spring Boot app that works smoothly when it connects to an Oracle instance in the classic way: jdbc:oracle:thin:@<server name>:<port num>/<service name> However, when I turn to a connection via tns through a tnsnames.ora stored in my local drive "C:\ORACLE\Client11g\network\admin" something doesn't work and I get this exception: Caused by: org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment] at org.hibernate.service.internal.AbstractServiceRegistryImpl.createService(AbstractServiceRegistryImpl.java:267) at

Connection to Oracle via TNS is not working

不想你离开。 提交于 2019-12-01 05:37:26
问题 I have a Spring Boot app that works smoothly when it connects to an Oracle instance in the classic way: jdbc:oracle:thin:@<server name>:<port num>/<service name> However, when I turn to a connection via tns through a tnsnames.ora stored in my local drive "C:\ORACLE\Client11g\network\admin" something doesn't work and I get this exception: Caused by: org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment] at org

Oracle database TNS The value's length for key 'data source' exceeds it's limit of '128'

做~自己de王妃 提交于 2019-11-30 22:13:35
So I have a connection string to an Oracle Database essentially I copied it straight from sql developer and then cut out the white space. I later programmatically add in the user name and password.The problem is that when I try to open an SQLConnection object. I get the error: The value's length for key 'data source' exceeds it's limit of '128' I don't really know much about oracle TNS connections. I used this connection string because it worked in the wizard when I pasted it in and did test connection. And what you see is essentially what Visual studio generated after I pasted in the TNS name

Querying an Oracle database from SQL Server

好久不见. 提交于 2019-11-30 21:25:29
I have an Oracle 11g XE database that I would like to transfer into SQL Server Express 2005. At first I thought I'd just generate the tables in Oracle as SQL, manipulate the data formats, and run the query in SQL Server. This worked for small tables, but I have several tables with a few hundred thousands rows and some with millions of rows, so this solution won't work. I then created a TNS file with the following content: OracleTnsName = ( DESCRIPTION= ( ADDRESS = (PROTOCOL=TCP)(HOST=localhost)(PORT=1521) ) ( CONNECT_DATA = (SERVICE_NAME=XE) ) ) I followed instructions I found elsewhere on how

How to set proper path to TNSNAMES file in C# application?

情到浓时终转凉″ 提交于 2019-11-30 21:04:00
I have a program in C# that use ODP.NET dlls: oci.dll, ociw32.dll, Oracle.DataAccess.dll, orannzsbb11.dll, oraocci11.dll, oraociicus11.dll, OraOps11w.dll. I've got 2 computers. First with whole ODAC package installed, and second without that package. But I have all required dlls in my exe directory, so ODAC is not a problem I think. The difference between these computers is the path to the TNSNAMES file. First: C:\app\OraHome_1\Network\admin\ Second: C:\Oracle\product\11.2.0\client_1\network\admin On the first computer, the program works fine. But on the second one with the same connection

How to set proper path to TNSNAMES file in C# application?

半腔热情 提交于 2019-11-30 17:15:52
问题 I have a program in C# that use ODP.NET dlls: oci.dll, ociw32.dll, Oracle.DataAccess.dll, orannzsbb11.dll, oraocci11.dll, oraociicus11.dll, OraOps11w.dll. I've got 2 computers. First with whole ODAC package installed, and second without that package. But I have all required dlls in my exe directory, so ODAC is not a problem I think. The difference between these computers is the path to the TNSNAMES file. First: C:\app\OraHome_1\Network\admin\ Second: C:\Oracle\product\11.2.0\client_1\network

Oracle - What TNS Names file am I using?

↘锁芯ラ 提交于 2019-11-30 06:16:15
问题 Sometimes I get Oracle connection problems because I can't figure out which tnsnames.ora file my database client is using. What's the best way to figure this out? ++happy for various platform solutions. 回答1: Oracle provides a utility called tnsping : R:\>tnsping someconnection TNS Ping Utility for 32-bit Windows: Version 9.0.1.3.1 - Production on 27-AUG-20 08 10:38:07 Copyright (c) 1997 Oracle Corporation. All rights reserved. Used parameter files: C:\Oracle92\network\ADMIN\sqlnet.ora C:

Parsing tnsnames.ora using regex

主宰稳场 提交于 2019-11-29 15:28:59
I am attempting to pull some information from my tnsnames file using regex. I started with the following pattern: MYSCHEMA *? = *?[\W\w\S\s]*\(HOST *?= *?(?<host>\w+\s?)\)\s?\(PORT *?= *?(?<port>\d+)\s?\)[\W\w\S\s]*\(SERVICE_NAME *?= *?(?<servicename>\w+)\s?\) which worked fine when MYSCHEMA was the only schema in the file, but when there are other schemas listed after MYSCHEMA it matches all the way to the last schema. I have since created a new pattern: MYSCHEMA *=\s*\(DESCRIPTION =\s*\(ADDRESS *= *\(PROTOCOL *= *TCP\)\(HOST *= *(?<host>\w+)\)\(PORT *= *(?<port>\d+)\)\)\s*\(CONNECT_DATA *=\s

How to install ODP.NET 2.111 and ODP.NET 4.112 in the same machine side-by-side while both point to the same database server

痞子三分冷 提交于 2019-11-29 12:59:53
The question is how to install ODP.NET 2.111 and ODP.NET 4.112 in the same machine side-by-side while both point to the same database server using tnsnames.ora I need to support a legacy system based on Oracle 11.1.0. The system is using ODP.NET 2.111 to connect to oracle. There are two clients installed at: C:\oracle\product\11.1.0\client_1 C:\oracle\product\11.1.0\client_2 The tnsnames.ora for both is something like this: xxxx1_SERVICE= (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = xxxx2)(PORT = xxx3)) (CONNECT_DATA = (SERVER = DEDICATED) (SID = xxx4) ) ) yyyy1_SERVICE = (DESCRIPTION =