RE: Locating error position in DBD::Oracle

2004-04-20 Thread Fannin, David P.
PHONE (573) 341-6375 --- -Original Message- From: Andy Hassall [mailto:[EMAIL PROTECTED] Sent: Monday, April 19, 2004 3:35 PM To: Fannin, David P.; [EMAIL PROTECTED] Subject: RE: Locating error position in DBD::Oracle Yes, use $dbh-{ora_parse_error_offset

Locating error position in DBD::Oracle

2004-04-19 Thread Fannin, David P.
Some sql editors, such as sqlplus, seem to be able to locate the position within an SQL statement where a syntax error occurs. I have looked through the DBD::Oracle documentation and have not been able to find such a thing mentioned. Does DBD::Oracle support this, or is it a feature that can not

RE: Perl with Oracle 9.2

2003-10-14 Thread Fannin, David P.
Chris, As long as you keep the 8.1.7 ORACLE_HOME around to support your existing perl installation, you should not have to recompile. In my experience, the 8.1.x libraries work fine for communicating with Oracle 9.x servers. My experience is limited to Red Hat Linux, though. I have compiled

RE: Connecting to Oracle through Perl.

2002-09-18 Thread Fannin, David P.
The Oracle client looks for tnsnames.ora in the $ORACLE_HOME/network/admin directory. We typically set the Perl variable $ENV{ORACLE_HOME} to the location of the Oracle installation in our database connection modules prior to any attempt to open a database connection. -dpf-

RE: Inserts in multiple tables

2002-04-18 Thread Fannin, David P.
Have you looked at the DBI documentation for $dbh-commit and $dbh-rollback? You have to make sure AutoCommit is off, but this too is explained in the documentation for these functions. I found perldoc DBI to be sufficient for anything I needed to do. -dpf- --- David P.

RE: Whitespace being truncated with Oracle

2002-02-28 Thread Fannin, David P.
For my personal edification, could someone point me at the site where ANSI SQL is documented? I'm just curious to find out how far from standard Oracle is. Thanks! -dpf- --- David P. Fannin Database Administrator [EMAIL PROTECTED] UM-Rolla

RE: Re: Oracle DBI commit/rollback question...

2002-02-07 Thread Fannin, David P.
Looking at the Oracle 8 Server Concepts manual, a transaction is committed explicitly by a commit statement or implicity when a DDL statement is issued. My understanding is that a create table statement is a DDL statement. Thus an implied commit occurs at that point in your code and you can

RE: Inserting spaces into a NOT NULL column

2002-02-05 Thread Fannin, David P.
I had a similar problem before and was forwarded the tidbit below. I can't tell from the description of your problem if it is exactly the same as what I was experiencing. I hope this helps. This tip courtesy of Tim Bunce: use DBI qw(:sql_types); $sth-bind_param(1, $value, SQL_CHAR);

RE: 'CREATE INDEX' and DBD-ORACLE?

2002-01-15 Thread Fannin, David P.
Have you tried a SELECT query against your materialized view to make sure there isn't a permissions problem with the view or one of the underlying tables? -dpf- --- David P. Fannin Database Administrator [EMAIL PROTECTED] UM-Rolla Computing

RE: Another1 problem with Oracle

2002-01-09 Thread Fannin, David P.
As of Oracle 8.0.5, the DESCRIBE command was not part of the server code. It was only supported by tools such as sqlplus. I have not tried newer versions of Oracle, but I notice that DESCRIBE is not in the SQL Reference for 9i. Here is a query that should work for you: SELECT COLUMN_NAME,

RE: How to safetly check an SQL statement?

2002-01-09 Thread Fannin, David P.
Stan, I don't completely understand your application, but here is the query I'd use. SELECT COUNT(*) FROM ALL_OBJECTS O, ALL_TAB_COLUMNS C WHERE O.OWNER = 'FOO' AND OBJECT_NAME = 'BAR' AND COLUMN_NAME IN ('BLAH', 'RAH') AND OBJECT_TYPE IN ('TABLE', 'VIEW') AND O.OWNER = C.OWNER AND TABLE_NAME

RE: ReL DBD-ERROR: OCIServerAttach - ORA-12514

2001-12-31 Thread Fannin, David P.
John, At the minimum, the Oracle client needs to know where ORACLE_HOME is. All of our scripts set $ENV{ORACLE_HOME} to the correct value prior to attempting to establish a new database connection. That being said, I'm not convinced the problem is with an environment variable. To me, this

RE: DBD::Oracle -- bind variables treat string of spaces as NULL

2001-12-10 Thread Fannin, David P.
and Information Services FAX (573) 341-4216 URL http://www.umr.edu/~dpf PHONE (573) 341-4841 --- -Original Message- From: Tim Bunce [mailto:[EMAIL PROTECTED]] Sent: Monday, December 10, 2001 6:54 AM To: Fannin, David P. Cc: '[EMAIL PROTECTED]' Subject: Re: DBD

RE: :Oracle.pm - use of uninitialized variable line 327.

2001-12-10 Thread Fannin, David P.
I have gotten around this by using the following: eval ('my $CatVal = $attr-{TABLE_CAT};'); -dpf- --- David P. Fannin Database Administrator [EMAIL PROTECTED] UM-Rolla Computing and Information Services FAX (573) 341-4216 URL

DBD::Oracle -- bind variables treat string of spaces as NULL

2001-12-07 Thread Fannin, David P.
I've got an application where I need to use bind variables to populate many tables of a reporting server nightly. I'm using DBD::Oracle to access the target server. If I use $sth-bind_param ($num, ' ') Oracle treats the string of spaces as a NULL in my insert statement. Since NULLS aren't

RE: DBD::Oracle -- bind variables treat string of spaces as NULL

2001-12-07 Thread Fannin, David P.
Message- From: Stephen Clouse [mailto:[EMAIL PROTECTED]] Sent: Friday, December 07, 2001 1:17 PM To: Fannin, David P. Cc: '[EMAIL PROTECTED]' Subject: Re: DBD::Oracle -- bind variables treat string of spaces as NULL -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Fri, Dec 07, 2001 at 12:52