Michael Bayer wrote:
On Dec 19, 2011, at 10:17 AM, jose soares wrote:
Michael Bayer wrote:
On Dec 19, 2011, at 3:28 AM, jose soares wrote:
I tried as you said Michael and this is the error message:
sqlalchemy.exc.DatabaseError: (DatabaseError) ORA-12154: TNS:could not resolve
the connect identifier specified
I tried like so:
sqlalchemy.dburi="oracle://user:password@SHELL"
and I also tried using the port number:
sqlalchemy.dburi="oracle://user:password@SHELL:1521"
but the error is always the same.
j
OK, but if you connect with cx_oracle:
cx_Oracle.connect(user='user', password='password', dsn='SHELL')
then it connects ? it should be the exact same thing.
not in this way:
cx_Oracle.connect(user='user', password='password', dsn='SHELL')
but in this way:
cx_Oracle.connect(user='user', password='password',
dsn=cx_Oracle.makedsn('myhost',1521,'SHELL').replace('SID','SERVICE_NAME'))
this is weird. What's in your tnsnames.ora ? Is there the chance that just
modifying tnsnames.ora or adding a new entry would solve this ?
Sorry for all the questions I just need to determine what SQLAlchemy should do
here, either add some new connect styles or just tell users to modify their tns
files....
this is my tnsnames.ora:
# tnsnames.ora Network Configuration File:
/usr/share/oracle/app/oracle/product/11.2.0/dbhome_1/network/admin/tnsnames.ora
# Generated by Oracle configuration tools.
LISTENER_SICER =
(ADDRESS = (PROTOCOL = TCP)(HOST = myhost.net )(PORT = 1521))
SFERACARTA_CONN =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = myhost.net )(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = SHELL))
)
--
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To post to this group, send email to sqlalchemy@googlegroups.com.
To unsubscribe from this group, send email to
sqlalchemy+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/sqlalchemy?hl=en.