Tried it that way, same error.
On Feb 18, 2011, at 12:33 PM, Bill Ward wrote:
> You're probably calling do($sql, @args) when you should call do($sql, undef,
> @args)
>
> On Fri, Feb 18, 2011 at 11:31 AM, Bruce Johnson <
> john...@pharmacy.arizona.edu> wrote:
>
ndeed good practice.
>
> Carl Furst
> o/~ What a difference a byte makes... o/~
>
> -Original Message-
> From: Bruce Johnson [mailto:john...@pharmacy.arizona.edu]
> Sent: Friday, February 18, 2011 3:07 PM
> Cc: DBI Users List (dbi-users@perl.org)
> Subject: Re:
No, this is done as:
$csr=$dbh->prepare($sql)
then as $csr->execute(@parms) inside of a loop.
On Feb 18, 2011, at 12:33 PM, Bill Ward wrote:
> You're probably calling do($sql, @args) when you should call do($sql, undef,
> @args)
>
> On Fri, Feb 18, 2011 at 11:31 AM,
27;A', :p6='0', :p7='Zimmt', :p8='Werner S', :p9='wsz']
at ./edsload.pl line 97, line 532.
I've counted three times: I have 19 fields in the db, 19 '?'s, and 19 param
values being passed, why am I getting this error?
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
v5.8.5 to connect to our Oracle
> 10.02.0400 dB.
make sure the query works in SQLPlus.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
x27;re getting any rows?
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
On May 6, 2010, at 11:34 AM, John Scoles wrote:
Bruce Johnson wrote:
Depends if you have |AutoCommit| on or not and if you DB and DBD
friver can do a rollback.
I've explicitly turned autocommit off, so I can roll back transactions
if an error occurs.
In the old Oraperl syntax
If $dbh is my database handle, to roll back the current transaction I
do: $dbh->rollback(); right?
The DBD::Oracle docs don't explicitly say....
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
$ora_errstr)..."
Oracle DBI doesn't stop the script, it just doesn't work, and goes to
the next statement.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
to be installed, you're SOL. You can try
doing what you need with sqlplus scripts and procedures.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
t;SELECT msgid, xmlcontent FROM messages WHERE msgid = 1892362" is
also mildly inefficient, why are you returning the msgid when you
already know it?
do "SELECT xmlcontent FROM messages WHERE msgid = 1892362" instead.
It's not much, but you're saving cycles and memory inside of a loop.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
here stuff is.
The simplest way to get MySQL working properly with the local perl, in
my experience, is to use MacPorts
<http://www.macports.org/> (used to be DarwinPorts), and make sure
the /opt/... paths are in your ENV.
--
Bruce Johnson
University of Arizona
College of Pharmacy
In
On Mar 26, 2010, at 11:01 AM, Bruce Johnson wrote:
Does the DBD enclose all parameters in ''s?
Am I actually trying to execute:
select reserved_id, reserver, purpose, to_char(starttime, 'HH:MI'),
to_char(stoptime, 'HH:MI') from reservedroomtest where room
x27;03/23/2010 19:00', 'MM/DD/
HH24:MM') <= starttime and to_date('03/23/2010 20:00', 'MM/DD/
HH24:MM') >= starttime) or (to_date('03/23/2010 19:00', 'MM/DD/
HH24:MM') >= starttime and to_date('03/23/2010 19:00', 'MM/DD/
HH24:MM') < stoptime))
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
have to set it in my code.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
t
you're saying it's just a dummy value, it just has to have a value?
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
n running for 6 or 7 years now and currval = 127,616).
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
On Jan 5, 2010, at 10:11 AM, John Scoles wrote:
Bruce Johnson wrote:
I've got to update DBD::Oracle on a production machine (from our
antique 1.17 version to the current one), in the process I'm
changing the Oracle client as well.)
will the proper setting of the enviro
racle" via cpan
suffice or do I have to go in and rip out the old stuff first...
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
n set
environment variables like ORACLE_HOME via httpd.conf.
This is how we do it.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
lse {
$sth2->execute($c1, $memo);
}
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
mechanism to do an 'external
connect' and they seem to have opted for NO backward compatibility in
this regard.
How a bout going low and sneaky, and providing a username and password
with appropriate privs for one or the other hardcoded into the app?
--
Bruce Johnson
Universit
/lib
... the above is wrong. Lose the final '/lib'
Knew it was something blindingly obvious I missed.
Thanks!
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
y're using the old ora_perl connect syntax: $lda =
&ora_login($dbname,$login,$dbpass); substituting 'use Oraperl;' and
using the old connection command produces the same error.)
$dbname is of the format:
"host=host-name.pharmacy.arizona.edu;sid=actual-sid"
I'm sure it
sql code that is passed to the database:
insert into institution (instid, inst_name, is_zoo) values
(institution_seq.nextval, 'Roadrunner Zoo of The Canyons', 'Y')
returning instid into :INSTIDNO
So I know it's going out.
If I omit the 'returning instid into :INSTIDNO' part
under
Cheers
John Scoles
as one would be using
Bruce Johnson wrote:
here's my problem. Due to some ancient database infrastructure I
need to use an old version of DBD::Oracle compiled against an
Oracle 8i client libs.
We're setting ORACLE_HOME and LD_LIBRARY_PATH to be inherited fro
he) to use the new client and
DBD::Oracle to use the old?
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
ce.
As I said it's a weird thingit's that the 'thwe query is
successful but doesn't return rows' of the OP in this thread is the
same symptom that I have.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
racle
8.1.7 libs it works...); sqlplus on my Oracle 11 system does return
rows.
It's possible that the Oracle ODBC client is doing the same sort of
thing to you.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinio
httpd process, usually root. I think I ran into something similar when
I was setting up our new server a while back.
I had to put a directive into the httpd.conf file:
PassEnv LD_LIBRARY_PATH
with the appropriate settings.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Techn
ax; check
the manual that corresponds to your MySQL server version for the right
syntax to use near ' curdate())' at line 1 at ./
webdirectory_updater.pl line 128."
I cannot mix parameters and functions like that?
--
Bruce Johnson
University of Arizona
College of Pharmac
BINARY
NLS_CALENDARGREGORIAN
NLS_NCHAR_CHARACTERSET US7ASCII
Only difference is the NLS_CHARACTERSET and NLS_NCHAR_CHARACTERSET,
but none of this involves anything unusual in the characters sets I
believe, it's all ascii data.
--
Bruce Johnson
University of Arizona
Colle
DS 0 (0 Active)
dbih_clearcom 0x8265f78 (com 0x81513a8, type 1) done.
! <> DESTROY for DBI::dr=HASH(0x8265f78) ignored (inner handle gone)
---
test.pl
#!/usr/bin/perl
use DBI;
$login="frs";
$dbpass="xx";
$dbname = "phmweb";
@nums = (0 .. 9);
#make random part for tracefile
$a .= join("", @nums[ map { rand @nums } ( 1 .. 4 ) ]);
$fname = "trace$a.trace";
open(my $outf, ">$fname")
or die "Couldn't open $fname $!\n";
$tracelevel = 6;
DBI -> trace($tracelevel, $outf);
$sq1 = "select first_name, last_name from employees_u where eid =
'060007454'";
my $dbh = DBI->connect( 'dbi:Oracle:phmweb',
$login,
$dbpass,
) || die "Database connection not made:
$DBI::errstr";
my $sth = $dbh->prepare($sq1);
$sth->execute();
my ($fn, $ln);
$sth->bind_columns(undef, \$fn, \$ln);
while( $sth->fetch() ) {
print "My name is $fn $ln or it should be \n";
}
close(OUT);
exit;
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
t via Database Links, etc.
I and our RDB DBA checked out the compatibility issue first, the
latest version of the OCI pServer emulates a Oracle 10.2 database.
cheers John Scoles
Bruce Johnson wrote:
I've been banging my head against the wall for two weeks now on
this one.
I'm des
t a query through the database link, I can see the
connection made, the query passed on, and column names come back, but
no data.
I can watch the SAME QUERY being run through SQLPlus and it works.
Is this a DBD::Oracle bug? an OCI bug? Something I haven't thought of?
--
Bruce Johns
version CPAN gives me is 1.22.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
On Aug 27, 2008, at 5:52 PM, Douglas Wilson wrote:
On Wed, Aug 27, 2008 at 11:41 AM, Bruce Johnson
<[EMAIL PROTECTED]> wrote:
Is anything 'baked-in' from the oracle environment to a DBD:Oracle
install
at the time of installation?
I'm having some weird problems invol
ust by changing LD_LIBRRY_PATH and
ORACLE_HOME?
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
fixed it, thanks.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
(only relevant ones listed.)
CGI Environment
ORACLE_HOME = /home/oracle/product/10.2.0/db_1
LD_LIBRARY_PATH = /opt/lampp/lib:/opt/lampp/lib:/home/oracle/product/
10.2.0/db_1/lib
What else could cause this problem?
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology
wrong.
The question may be academic anyway, I've been told we're nuking and
re-building the server all over again as an exercise anyway. If it
recurs, I know how to fix it.
--
Bruce Johnson
University of Arizona
College of Pharmacy
Information Technology Group
Institutions do not have opinions, merely customs
wrong.
The question may be academic anyway, I've been told we're nuking and
re-building the server all over again as an exercise anyway. If it
recurs, I know how to fix it; kludge it, rather, not fixing the
underlying problem.
--
Bruce Johnson
University of Arizona
College of P
On Jul 29, 2008, at 11:51 AM, Bruce Johnson wrote:
Perl 5.8, DBI 1.607, DBI::Oracle 1.21, Oracle 11g (11.1.0)
Any script I try to run results in the error:
Database connection not made: ORA-12505: TNS:listener does not
currently know of SID given in connect descriptor (DBD ERROR
execute();
print &PrintHeader;
#DBI::dump_results($ret);
my ($thedate);
$ret->bind_columns(\$thedate);
while(($thedate) = $ret->fetchrow_array) {print "Today's date is
$thedate \n";}
$dbh->disconnect();
exit;
The ENV stuff was attempts to see if it was some environmen
101 - 144 of 144 matches
Mail list logo