Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Oraperl CGI Problem! Help...

Re: Oraperl CGI Problem! Help...

From: Garth Kennedy <garth_at_viola.comm.mot.com>
Date: 1997/04/01
Message-ID: <1997Apr1.133020.21208@schbbs.mot.com>#1/1

How about giving it a Database name, login ID and password ?

You may also want to switch to perl5 using DBI and DBD-Oracle. Better performance and more flexibility (on the perl side). You should not have to change your oraperl code.

Garth

In article <33402945.68F2_at_globalserve.net>, Angus Lai <orange_at_globalserve.net> wrote:
>Dear friends,
>
> I using oraperl to retrieve data from oracle, the following code
>work
>well on unix prompt (By typing ./ScriptName to test).
>-----------------------------------------------------------
>#!/usr/local/bin/oraperl
>
>require 'cgi-lib.pl';
>print &PrintHeader;
>
>$CityGetBrife = "select address from TABLE where upper(city) like
>‘%TORONTO%’";
>#Connect Oracle
> $lda = &ora_login($DataBase, $ID, $Pass)||print "login error
>:$ora_errstr<p>\n";
>
> #open and send SQL
> $csr = &ora_open($lda, $CityGetBrife, 6)||print "Open Error :
>$ora_errstr<p>\n";
> while(($tra) = &ora_fetch($csr)) {
> push(@BranchList, $tra);
> }
> print @BranchList;
>
> do ora_close($csr) || die "can't close cursor";
> do ora_logoff($lda) || die "can't log off Oracle";
>------------------------------------------------------------
>But When I run the program with web
>broswer(http://domain/ScriptName.pl), It cannot login Oracle.
>$ora_errstr is : Error while trying to retrieve text for error ORA-12546
>
>Dear friend, What is this error message means? can u think of some
>solution? What's happening?
> Thanks A LOT.
>
>-Angus
Received on Tue Apr 01 1997 - 00:00:00 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US