Error: ORA-12154 SQL Server Link Server with Oracle 11g in Windows Server 2012 R2 - sql-server

I need to create Link Server in SQL Server 2012 Enterprise 64 using Oracle ODAC.
I have done everything I know, including multiple re-installation of Windows Server 2012 Standard R2 64. The ODAC is also 64bit.
I am able to connect to Oracle 11g using Oracle SQL Developer using TNS as Connection Type.
I am beginning to think this may have something to do with Windows Server. Because I have never experience this issue on other systems not running Windows Server.
I get this error:
returned message "ORA-12154: TNS:could not resolve the connect identifier specified.
Thanks

After combining through hundreds of internet posts and install/reinstall. I discovered the problem was the ORACLE ODAC Components. Every article on the internet tells you to install 64bit ODAC if you are running 64bit database, however, this is not accurate.
After spending two days trying to get this to work, I decided to try the 32bit ODAC and it worked.
In case anyone is having this same issue.

Related

SQL Server 2019 cannot see Oracle 12.2.0 OraOLEDB12.dll in Providers list

My SQL Server 2019 Enterprise is up and running on a Windows 2019 Core vm. Connections to SQL Server databases are A-OK.
I have installed the OLEDB driver OraOLEDB12.dll via the oui.exe in the ODTwithODAC122011.zip.
I checked only the Oracle Provider for OLE DB in the Component Name list.
It created the appropriate TNSNAMES.ORA file from the info I provided.
The installer added the appropriate paths to the environment var PATH.
After restarting the Windows 2019 Core VM, and reconnecting SSMS v18.8 to the SQL Server I could not see the provider in the Server Objects, Linked Servers, Providers list.
So I ran regsvr32.exe and got back DllRegisterServer in OraOLEDB12.dll succeeded. So I restarted the VM again, and reconnected to my SQL Server and still no joy.
What am I missing here? I've search through lots of google links, on StackOverflow itself and am finding the same results, path issues, registry issues, 32/64 issues. Our Ent SQL Server is x64, our SSMS locally is X64, the Oracle driver is x64.
Did you try to install more than one Oracle client? Oracle OLEDB driver can exist only once (i.e. once each for 32-bit and 64-bit).
Version of Oracle OLEDB driver must match exactly the Oracle client.
Maybe have a look at my Oracle Connection Tester, this may give you an indication whether your Oracle OLEDB driver is properly installed.
Gentlepersons,
My apologies, I did indeed install the 32 bit driver when I thought I was installing the 64 bit.
Have deinstalled (as Oracle calls it) the previous and am moving forward with the correct installation.
Again, my apologies for wasting time.
G

Significant performance differences between Access on Windows Server 2008 R2 and Windows Server 2019

In our company we have to support a large legacy system built on Microsoft Access 2010 as frontend and SQL Server 2008 R2 as backend. The backend SQL server runs on Windows Server 2008 R2. Currently our users works on Terminal Server sessions on a Windows Server 2008 R2. A couple of days ago we started to test Windows Server 2019 and Notebooks with the latest version of Windows 10. We recognized a big performance difference while executing the same Access databases on the different environments.
For instance the creation of a report takes 27 seconds (new environment) instead of 7 seconds (old environment). The database.accdb is identical, the backend is identical (still Windows 2008 R2 Server with SQL Server 2008 R2 and SP2), only the execution environment (Windows) changed.
Does anyone of you have an idea how to explain this?
In Access 2010 the SQL server tables are linked using System-DSN data sources. On the old environment ODBC is used (Driver: SQL Server, Version: 6.01.7601.17514).
On the new environment I tested the following drivers:
ODBC Driver 11 for SQL Server (2014.120.5543.11)
ODBC Driver 17 for SQL Server (2017.173.01.01)
SQL Server (10.00.17763.01)
SQL Server Native Client 10.0 (2009.100.4000.00)
SQL Server Native Client 11.0 (2011.110.5058.00)
I created a new System-DSN using the different drivers and updated the linked tables in Access. But in any case the performance is still bad. I also tested the latest version of Access which comes with Office 2019, but again it is slow.
Sounds like your terminal sessions are getting throttled. Despite the fact that you have a SQL Server back end, Access is still doing a fair bit of thunking with the result sets, so any resource throttling differences between your Server 2008 and Server 2019 policies could be choking Access in the new server.
I think your answer is going to be found in Windows System Resource Manager. The page says it's not being maintained, but following the "Recommended Version" link leads to a generic Server 2019 page. Here's another article about how WSRM might be throttling sessions: Using WSRM to control RDS Dynamic Fair Share Scheduling.
Compare the Weighted_Remote_Sessions policy in 2008 and 2019 servers. There's either been a change to the default settings or behavior or the 2008 server policy was modified in the past to get to the current performance level.
Ok, a number of things to check.
First thing to check:
Launch the ODBC manager and check if SQL log tracing is on. I don’t know why, but I see sql logging turned on.
You NEED to be 100% sure it is turned off.
You MUST launch the ODBC manager from the command line or start menu, since the one in the control panel is for the x64 bit version, and you are using Access x32 (I assume).
So launch this version:
c:\Windows\SysWOW64\odbcad32.exe
So VERY important to launch the x32. It is assumed you are using a FILE dsn. So check these two settings:
(Make sure they are un-checked).
Next up?
Link access using the IP address of the sql server.
So, place of say:
myServer\SQLEXPRESS
Use:
10.50.10.101\SQLEXPRESS
(Of course use the IP address of sql server, not the above “example” IP).
The above things are quite easy to check.
Still no performance fix?
Then disable the fire wall on your new Terminal server (I seen this REALLY cause havoc).
And, disable windows defender on the new TS server if running.
The above tips should fix your issues.
If above don’t work, then next would be to check the priority settings for the TS server (GUI over server).
However, I am betting the above checks should restore your performance.

SQL Server 64-bit ODBC Connection to 32-bit Pervasive SQL v10

I am using the 64-bit version of SQL Server 2016 Express, trying to connect to a 32-bit Pervasive SQL v10 database. I am setting up a Linked Server in SQL Server via ODBC connection, but I am receiving this error that has given me a lot of pain in the past:
The specified DSN contains an architecture mismatch between the Driver and Application
I had a similar issue not long ago trying to connect to a Microsoft Access database, but with help here I was able to obtain the 64-bit ODBC driver for Access. However, there does not seem to be one for Pervasive v10 at all, only for PSQL v11+, which does not help me in this case.
Previous question: SQL Server Linked Server to MS Access - DSN Architecture Mismatch Error
So if anyone has a suggestion for connecting to a 32-bit client from a 64-bit SQL Server installation, when there does not exist a 64-bit ODBC driver for this client, please let me know.
One of the suggested solutions was to use an OLEDB link instead (but no details provided on this, and I'm not sure how it would differ from the linked server I am already trying to create, which is already using OLEDB).
There was also mention somewhere of installing an entirely separate 32-bit SQL Express client, and chaining an additional ODBC link to point to the first one, but I would rather avoid all that overhead if possible, especially since this is a production server that is already running Sage 50 in addition to our own software and web services with SQL Server...
Other details: The client that is built on Pervasive SQL v10 that I am trying to connect to is Peachtree 2017 - Sage 50. This is all running on Windows Server 2012 R2 Standard.
More reading here:
https://support.na.sage.com/selfservice/viewdocument.do?noCount=true&externalId=12693&sliceId=1&cmd=displayKC&dialogID=50216&docType=kc&noCount=true&isLoadPublishedVer=&stateId=50217&docTypeID=DT_Article&ViewedDocsListHelper=com.kanisa.apps.common.BaseViewedDocsListHelperImpl
https://www.experts-exchange.com/questions/23995371/Installing-Pervasive-SQL-Client-on-Windows-2008-64bit-missing-ODBC-Driver.html
Edit:
Thanks for the comments! After further investigation... it looks like this IS actually PSQL v11, not v10. Now, I'm not sure why the 64-bit ODBC driver is not already installed... but I am looking into this now...

Trying to connect to an Oracle server v9.2.0.8 with the pycharm database tool

I'm trying to use the PyCharm database tool to look at a couple of Oracle databases. The first database is an Oracle 11 database and connects with no problems. The second database, however, is an Oracle 9i database and is giving me issues. When i try to connect to it I get an error message that says
Unsupported combination of server/driver versions: found Oracle server version 9.2.0.8 with JDBC driver version 12.1.0.2 that is not compatible. Oracle server version 9.x must be connected by JDBC driver versions 9.x to 11.x..
I've tried finding where pycharm keeps the JDBC drivers but have had no luck. If someone could point me in the right direction I would be very grateful. I would also appreciate it if someone could point me towards where I can download drivers that will work with the Oracle 9i and 11(g i think?) databases.
I'm on windows 10 64 bit and using PyCharm 2016.2.3.
I have been using Oracle Server 9i- 9.2.0.4.
To query on this server I am using Jet Brains DataGrip.
It showed me the same error and then I changed driver jar of ojdbc6-x.x.x with
ojdbc14-9.2.0.1.jar and then It started working fine on DataGrip.
Hope this will be helpful.
Download ojdbc14-9.2.01 and configure it on your local Database management tool.
http://www.java2s.com/Code/Jar/o/Downloadojdbc149201jar.htm

Connect oracle 11g client from windows 7 to Windows server 2008

Good afternoon dear all. I am Shaiju.I need your advice on installing Oracle 11g database client software in my windows 7 64 bit OS workstation. The following is my scenario.
I have installed Oracle Database 11g 64 bit on my server (Windows 2008 R2 Standard 64 bit). It works well.
I have to access the database from my client machine (Windows 7 64bit). I have installed oracle database 32 bit client in the workstation. I chose Administrator mode method while installing the oracle client software.
I copied tnsnames.ora, listener.ora from the server and pasted them in workstation under network\admin folder.
When I tried to connect the database through sqlplus, it could not connect the database. It says "Error: ORA-12541: TNS:no listener".
If you have any idea what could be the problem, please advise me how to sort it out.
First I'll assume that the listener and database are up on your server (you can see them as windows services). If you don't know what you are doing I'd strongly recommend using the the oracle configuration assistant to modify the tns files and always keep a backup. They are very sensitive if you don't get the syntax right.
http://docs.oracle.com/cd/B16276_01/doc/server.102/b14196/network005.htm
You could also try easyconnect http://docs.oracle.com/cd/B19306_01/network.102/b14212/naming.htm#i498306

Resources