RE: How to call Oracle DBs via DBI ODBC

From: Ron Reidy (Ron.Reidy_at_arraybiopharma.com)
Date: 01/17/05

  • Next message: Michael A Chase tech: "Re: DBD Oracle DBI driver"
    Date: Mon, 17 Jan 2005 11:39:32 -0700
    To: "Moreno, Javier" <JavierMoreno@eaton.com>, <dbi-users@perl.org>
    
    

    Javier,

    Did you not like my response from Jan 16? Again:

    This is not a Perl/ODBC issue. This is a problem with Oracle. From the oerr utility:

    12514, 00000, "TNS:listener could not resolve SERVICE_NAME given in connect descriptor"
    // *Cause: The SERVICE_NAME in the CONNECT_DATA was not found in
    // the listener's tables.
    // *Action: Check to make sure that the SERVICE_NAME specified is correct.
    // *Comment: This error will be returned if the (database) service has not been
    // registered with the listener; a database instance that is part of this
    // service may need to be started or configured properly.

    Most likely your database is missing the 'local_listener' parameter.

    You need to speak with your DBA and have him/her fix it. If you do not have a DBA, go to

    http://download-west.oracle.com/docs/cd/B10501_01/server.920/a96536/ch188.htm#REFRN10082

    and read about it.

    -----------------
    Ron Reidy
    Lead DBA
    Array BioPharma, Inc.

    -----Original Message-----
    From: Moreno, Javier [mailto:JavierMoreno@eaton.com]
    Sent: Monday, January 17, 2005 11:32 AM
    To: dbi-users@perl.org
    Subject: How to call Oracle DBs via DBI ODBC

    All,

    I have a web application which calls an Oracle database. I was unable to connect to it but I found out it was because the HTTP port the TNS was listening to was not the same one the webserver was running on. I have fixed that on the webserver end. However, it seems the call to the TNS is getting mixed up. The DBI ODBC driver appears to be sending the HOST_NAME as SERVICE_NAME. My call is very standard, is there something else I should do in order for this to work?

    $::dbh = DBI->connect('dbi:ODBC:ILOG', 'system', '##########', { AutoCommit => 0 }) or
            &Error("Unable to connect to database.<br>$DBI::errstr");

    17-JAN-2005 11:18:19 * (CONNECT_DATA=(SID=*)(SERVICE_NAME=slpmxwmorenojav)(CID=(PROGRAM=C:\Perl\bin\perl.exe)(HOST=SLPMXWMORENOJAV)(USER=SYSTEM))) * (ADDRESS=(PROTOCOL=tcp)(HOST=151.110.117.153)(PORT=3772)) * establish * slpmxwmorenojav * 12514
    TNS-12514: TNS:listener could not resolve SERVICE_NAME given in connect descriptor

    Regards,

    Javier Moreno

    This electronic message transmission is a PRIVATE communication which contains
    information which may be confidential or privileged. The information is intended
    to be for the use of the individual or entity named above. If you are not the
    intended recipient, please be aware that any disclosure, copying, distribution
    or use of the contents of this information is prohibited. Please notify the
    sender of the delivery error by replying to this message, or notify us by
    telephone (877-633-2436, ext. 0), and then delete it from your system.


  • Next message: Michael A Chase tech: "Re: DBD Oracle DBI driver"

    Relevant Pages

    • Interview Questions(Oracle9i DBA), help me
      ... The DBA is attempting to back up the Oracle database control file. ... The request queue is common, and the response queue is different ...
      (comp.databases.oracle.server)
    • Re: acceptable way to program
      ... Objective research by Oracle and IBM have both shown ... Backup isn't a query with any commercial relational database. ... written in Crsytal Reports or Cognos and not have Java front-end. ... weigh heavily against even the knowlegeable DBA insisting that the ...
      (comp.lang.java.programmer)
    • RE: inserting XML Document into Oracle database using a stored procedure
      ... You say it the database is not being called. ... inserting XML Document into Oracle database using a stored ... Please notify the sender of the ... This electronic message transmission is a PRIVATE communication which contains ...
      (perl.dbi.users)
    • US-CA: Brisbane (SF Bay Area)-Senior Oracle DBA
      ... Shopping.com is looking to hire a senior Oracle database administrator ... CA office to join the existing DBA team ... Specific Responsibilities: ...
      (comp.databases.oracle.marketplace)
    • US-MI: Bloomfield Hills-Senior Oracle DBA Lead
      ... Job Title: Senior Oracle DBA Lead ... business units and be responsible for data quality, integrity, and database ... SQL Server, MySQL and Windows 2000/2003. ...
      (comp.databases.oracle.marketplace)