ORA-12154: TNS:could not resolve the connect identifier specified
The Oracle client couldn’t find the alias in tnsnames.ora (or the naming method can’t resolve it).
Seen on:
SQL
Meaning
The client looks up the alias in tnsnames.ora under TNS_ADMIN. Using EZConnect (host:port/service) avoids tnsnames entirely.
Common causes
- Alias missing from tnsnames.ora
- TNS_ADMIN not set / wrong file used
- Typo in the alias
⚡ Quick fix
- Use EZConnect: host:1521/servicename
- Set TNS_ADMIN to the right folder
- Check the alias spelling
Detailed fix by platform
SQL
sqlplus app/pass@//db.example.com:1521/ORCLPDB1
How to diagnose
- Alias — In tnsnames.ora?
- TNS_ADMIN — Which file?
🧠 Still stuck? Analyze your error
Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.
Was this page helpful?
Report a correction or suggest an improvement
Last updated 2 Oct 2026