Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Question
Thursday, May 7, 2015 8:39 PM
when I want to query data from Oracle database with PowerQuery, I received below error:
"DataSource.Error:Oracle:ORA-12154:TNS:could not resolve service name
Details:
Message=ORA-12154:TNS:could not resolve service name
ErrorCode=-2146232008"
But I can access same Oracle database via PowerPivot, can some one assist on this problem?
All replies (2)
Friday, May 8, 2015 7:53 AM ✅Answered
Hi,
Based on your error message, this error indicates that the service (or TNS alias) specified when trying to connect does not exist. ‘TNS aliases’ or ‘service names’ are defined locally to each workstation. Thus different workstations could have a completely different alias to refer to the same database.
And you can try to this method to connect to Oracle database.
Before you can connect to an Oracle database using Power Query, you need the Oracle client software v8.1.7 or greater on your computer. To install the Oracle client software, go to http://go.microsoft.com/fwlink/p/?LinkID=272376 and download (at minimum) Basic Instant Client for Microsoft Windows.
- In the POWER QUERY ribbon tab, click From Database > From Oracle Database.
- In the Oracle Database dialog box, in Server Name specify the Oracle Server to connect to. If a SID is required, this can be specified in the form of “ServerName/SID”.
- If you want to import data using native database query, specify your query in the SQL Statement box. For more information, see Import Data from Database using Native Database Query.
- Click OK.
- If the Oracle server requires database user credentials:
- In the Access a Database dialog box, enter your username and password.
- Click Save.
Please refer to this article about steps of connecting to Oracle database:
And you can refer to this article to get more information about your error message.
If this issue still exists, I suggest you post your issue to Power Query forum.
https://social.technet.microsoft.com/Forums/office/en-US/home?forum=powerquery
The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and other partners who read the forums regularly can either share their knowledge or learn from your interaction with us. Thank you for your understanding.
Hope it’s helpful.
Regards,
George Zhao
TechNet Community Support
It's recommended to download and install Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office programs.
Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact [email protected].
Friday, May 8, 2015 10:50 AM
Thank you.
It seems a incompatibility problem between Oracle 9i and 64-bit Win7.
I have download Oracle Instant Client and fixed one host.
But the trouble persisted on another PC.