cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Connection error to an Oracle XE database - TNS:could not resolve the connect identifier specified

Hi,

on my 64-bit machine I've installed the Oracle client/ODAC software and the Oracle Express Edition database (vers. 18c).

Using the SQL Developer I can connect to the XE cdb and the XEPDB1 pdv. Inside the XEPDB1 pdb I've created a new user/schema with some tables; inside Power Query I need to connect to this new user of XEPDB1.

Well, in PQ I've created successfully an Oracle connection to the XE cdb using SYSTEM as an user; in the tnsnames.ora file of the Oracle XE installation I've these settings:

pmscorca_0-1627984758039.png

 

Moreover, in PQ I've tried to create another Oracle connection to the new user/schema of the XEPDB1 pdb obtaining this error message: ORA-12154: TNS:could not resolve the connect identifier specified; in the tnsnames.ora file I've these settings:

new_user =
(DESCRIPTION =
(ADDRESS =
(PROTOCOL = TCP)
(HOST = xxx.xxx.local)
(PORT = 1521)
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = new_user)
)

 

I can connect with the new user inside SQL Developer and for creating an ODBC 64-bit data source.

So, it seems that the Oracle client is installed rightly and Power BI recognizes it, but an error occurs for the new user.

Now, any suggests to me in order to solve this issue, please?

Has the new user to have some particular high permissions for the XEPDB1 database?

Many thanks

2 REPLIES 2
v-stephen-msft
Community Support
Community Support

Hi @Anonymous ,

 

Sorry to disturb you.


Could you tell me if your problem has been solved?
If it is, kindly accept the useful reply as the solution. More people will benefit from it.
Or you are still confused about it, please provide me with more details about your problem.

 

Best Regards,
Stephen Tao

v-stephen-msft
Community Support
Community Support

Hi @Anonymous ,

 

Here'are some solutions you can refer to:

Verify a TNSNames.ora file exists on the QuickConnect server

 

Set the TNS_Admin environment variable if it is not set

  • Navigate to Control Panel > System
  • Select Advanced System Settings
  • In the Advanced tab, select Environment Variables
  • Under System Variables, click New
  • In the Variable name text box, type TNS_ADMIN
  • In the Variable value text box, type the location of the TNSNames.ora file
  • Click OK to add the variable
  • Restart the server

 

Reference: ORA-12154: TNS:could not resolve the connect identifier specified (213860)

 

Also, you can refer to these articels:

ORA-12154: TNS could not resolve service name tips

How to Solve the Oracle Error ORA-12154: TNS:could not resolve the connect identifier specified

ORA-12154 could not resolve the connect identifier specified

 

Best Regards,

Stephen Tao

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Carousel_PBI_Wave1

2023 Release Wave 1 Plans

Power BI release plans for 2023 release wave 1 describes all new features releasing from April 2023 through September 2023.

Power BI Summit Carousel 2

Global Power BI Training

Make sure you register today for the Power BI Summit 2023. Don't miss all of the great sessions and speakers!

BizApps LATAM 2023

Business Application LATAM Summit 2023

Join the biggest FREE Business Applications Event in LATAM this February.

Power Platform Bootcamp

Global Power Platform Bootcamp

In this bootcamp we will deep-dive into Microsoft’s Power Platform stack with hands-on sessions and labs, delivered to you by experts and community leaders.

Top Solution Authors
Top Kudoed Authors