try:
my $sth = $dbh->prepare( "set dateformat dmy" )|| die $dbh->errstr;
#to see if it's puking on prepare
or
$dbh->do( "set dateformat dmy" ) || die $dbh->errstr;
# this is the format I've learned to use for setting
# session params.
Daniel Kasak wrote:
Hi all.
The SQL Server docs sa
gt; from your computer. Although The Bank of New York attempts to sweep
> e-mail and attachments for viruses, it does not guarantee that either
> are virus-free and accepts no liability for any damage sustained as a
> result of viruses.
>
--
Jeff Seger <[EMAIL PROTECTED]>
Fairchild Semiconductor
ke which I have seen made is to put conditionals in the
> HAVING clause that should be in the WHERE clause instead. For example:
>
> SELECT status, MAX(id)
> FROM my_table
> GROUP BY status
> HAVING status IN (1, 2)
>
> should be
>
> SELECT status, MAX(id)
> FROM my_table
> WHERE status IN (1, 2)
> GROUP BY status
>
>
> Ronald
--
Jeff Seger <[EMAIL PROTECTED]>
Fairchild Semiconductor
> I'm a little confused by:
>
> $db->{LongReadLen}=some_number;
>
> This seems to me to effect insert and update but not read for text
> fields. Is that right?
>
Quite the opposite. It should not affect regular text (char, varchar)
fields at all, but only long, blob, memo etc and when it d
print "Table: $table\n";
> }
>
>
>
> -Mike
>
>
> At 11:49 AM 11/26/2002, Jeff Seger wrote:
> >I may be wrong...I seem to be making a habit of it lately...but I don't
> >think you can. SHOW TABLES is a mysql command, not an sql statement
I may be wrong...I seem to be making a habit of it lately...but I don't
think you can. SHOW TABLES is a mysql command, not an sql statement.
On Tue, 2002-11-26 at 10:02, darren chamberlain wrote:
> * Chris Rogers <[EMAIL PROTECTED]> [2002-11-26 09:45]:
> > Is there a way to get a list of all tabl
Maybe I am missing something herre (It is Monday after all) but
shouldn't a function be called in a select statement:
"select OWNER.MY_FUNCTION(?,$action,?,$meta_type) from dual"
or something similar?
On Mon, 2002-11-18 at 10:43, Michael A Chase wrote:
> On Mon, 18 Nov 2002 15:32:52 +0100 "NYIM
simple fix:
while( ($col1) = $sth_1->fetchrow_array){
because $sth_1->fetchrow_array returns an array, $col1 needs to be part
of a list context.
On Wed, 2002-10-16 at 13:10, Liu, Jenny wrote:
>
>
> The following simple sql statement just try to select a column from a table.
> But if the val
If the version of Perl that came with woody is a pre-compiled one, it's
important to compile the DBD/DBD packages with the same compiler. You
may want to re-install perl by compiling it from CPAN, then re-install
DBI/DBD by compiling it yourself.
HTH,
jeff
On Fri, 2002-09-20 at 08:34, William
Not sure as I am accustomed to Oracle. but that sounds like a similar
error message that you get in Oracle when the user you are connecting as
doesn't have select permissions on the table you are querying.
hth,
jeff
On Thu, 2002-09-12 at 12:37, Cheryl Duggan wrote:
> I have a cgi script that
Could you provide a code sample?
On Wed, 2002-09-11 at 10:51, sidi MOHAMED CHEINE wrote:
> I have a problem with dbi, I set up a system of
> capture of error.
> In my program I use two descriptors dbi, only when I
> intercept an error on the undes descriptors, the tests
> of errors $sth->err gi
On the other hand, if you need to pass connection attributes
(LongReadLen, LongTruncOK, RaiseError, etc) you may need to put in
empty strings for the user name and password:
$dbh=DBI->connect($connect_string, '', '', %attr); Or is it undefs? I
never touch the ODBC stuff myself.
HTH,
jeff
O
Ok, my best guess is that you have blank lines in your data file. You
may be passing an empty string to your prepare statement. What is on
line 16 of your datafile?
Also, at what point do you set the value of $file? You need to execute
and fetch the values from the first query into $file or y
Without code to look at, that's gonna be a tough one to figure out.
On Wed, 2002-06-26 at 12:51, Alan Hogue wrote:
> Hey, it looks like that was the problem! Thanks for your help.
>
> I am still having the same behavior from PTKDB, though. Does anyone have any
> idea why PTKDB would just die whe
1) I always re-compile DBD::Oracle when I change Oracle clients. I
don't know if this will fix the problem, but it's where I'd start.
2) Probably also a good time to upgrade your DBD::Oracle.
3) This would be a good time to upgrade your version of DBI.
On Wed, 2002-06-26 at 10:33, [EMAIL PROTECT
Are you certain that you have the correct path to the perl executable?
Try changing your shebang line to:
#!perl
and see if they are then executable.
On Mon, 2002-06-24 at 11:52, John Day wrote:
> 1.. Have you made the scripts executable? by using CHMOD 755 or something similar.
>You can ofte
Wrong list. This is not a DBI/DBD related question.
On Thu, 2002-06-20 at 16:40, perl is wrote:
> I want to find a way from PDF file to TXT file (may be
> use PDF package in perl). Does anyone know how to do
> that, with an example? thank you very much.
>
> Ping
> 6/20/02
>
> __
Did you:
use DBD::Oracle qw(:ora_types);
?
You may also need to reference $clob (\$clob) rather than passing a
copy, but I'm not sure on that.
HTH,
jeff
On Thu, 2002-06-20 at 11:36, David Totten wrote:
> Hello, I am new to the list, and I have searched the archives for this
> problem, and hav
Don't put SYSDATE in the execute. Put it in the prepared statement:
my $sth = $dbh->prepare( "INSERT INTO stats VALUES (SYSDATE,?,?,?,?)" )
or die "Cannot prepare SQL statements from $DBI::errstr\n";
foreach (@stats){
chomp;
($host, $user $cpu_pct, $mem_pct = split( /,/
Again, you need to check the variable scope of $sth. The error that you
are getting indicates that $sth is not defined within the current
context. Assuming that $sth is properly scoped, you should be able to
call fetch on it at any point within your code.
On Wed, 2002-06-12 at 13:10, pascal b
My understanding is that you cannot pass keywords as parameters because
the RDBMS cannot confirm the validity of the statement and thus cannot
prepare it. As a matter of fact, it doesn't even know what the whole
statement will be with a bind variable in that position.
Similarly keywords
On Mo
$sth->execute(undef);
On Thu, 2002-05-30 at 14:01, [EMAIL PROTECTED] wrote:
>
> Howdy,
>
> I've got an application that pulls data from an Oracle database to an IBM
> DB/2 database. For the IBM database, if the data I'm pulling contains all
> zeros or all spaces, they want me to insert a N
Well, perhaps if you posted some code we could have a little better
chance of seeing what the problem was.
On Fri, 2002-04-05 at 06:33, Bogdan Badiu wrote:
>Hello !
>I want to use Windows 98 /2000 , perl 5.6.1 and DBI and DBD-mysql
>
Using just forks is ok, using just DBI a
If you are running apache with mod_perl and if the site has more than a
couple of visitors an hour and you use Apache::DBI for connection
pooling, you can bet that you will speed up by using DBI. A lot. A
whole lot.
On Wed, 2002-04-03 at 18:33, Peter Scott wrote:
> At 04:28 PM 4/3/02 -0500, Kevi
That looks a bit off to me.
Try something like this:
$dbh->do(qq{UPDATE systems SET column_name = $value WHERE Name =
$name});
On Tue, 2002-04-02 at 12:01, NIPP, SCOTT V (SBCSI) wrote:
> New problem now. I appear have resolved my earlier problems. The
> final issue appears to have been t
We run sqlldr at run time all the time. Here is the
syntax, minus a bit of error checking. Obviously,
you'll need to set the variables according to your own
environment.
But we do inserts of hundreds of thousands of rows for
each of several dozen tables daily and issuing an
insert for each
Um, shouldn't that be:
perl -MCPAN -e 'install Bundle::DBI'
or alternatively:
perl -MCPAN -e shell
install Bundle::DBI
???
Kenny Smith wrote:
> Murali,
>
> ppm has not been installed with my AIX perl. I did a find ppm and it is not
> on the RS6000. Do I need to install ppm?
> ps: Correction
What you need to successfully install the DBD::Oracle is a full *client*
install of Oracle. You do not need a full server install and that may be
where the confusion is.
Leonardo Barbosa e Oliveira wrote:
> Sir,
>
> First of all, Thanks!But actually what I've heard
> was that I need some libs a
t; BTW, is a column name with space in name called "SQLSpecialColumns"?
>
> > -Ursprüngliche Nachricht-
> > Von: Jeff Seger [mailto:[EMAIL PROTECTED]]
> > Gesendet: Freitag, 11. Januar 2002 16:55
> > An: Carsten Schäfer
> > Cc: [EMAIL PROTECTED]
> &
Alright I just took a quick peek at CPAN's website and saw that
SQLSpecialColumns are supported starting with version DBD::ODBC 0.28 and there
is a bug fix in version 0.29 for them. So if you are using version 0.27 or
earlier, you may want to get the latest and greatest.
See http://search.cpan
I think, though I have only used LookOut Express, and that only infrequently,that you
can right click on a message on the list and choose properties. Totally intuitive.
No, really, totally.
Laurie Gennari wrote:
> >Surely Outlook has a way of letting you view message headers?
>
> Open the me
If the query just hangs there in mysql, putting it into DBI is not going to fix
that. Are the columns indexed in the tables? If not, you've probably got it
doing nested full table scans. Try adding indexes to the tables on the join
columns.
Get the query to run in mysql before you ever try it
In your script's shebang line, are you perhaps using:
#!/usr/local/bin/perl
?
Try a "which perl" from the command line and see if it varies from your
shebang line. Perhaps /usr/bin/perl?
Jake Hoban wrote:
> Hi
>
> I'm new to this list, but I've looked through the archives before
> posting and
>From my reading of it, you only have to worry about fees if you are developing
commercial applications which themselves use QT. TOra, which is itself GPL'd,
uses the free version of QT.
qw{
I just want to run KDE on my machine. Can I do that with the
Free Edition?
1. Yes, you need a c++ compiler if you are going to use the tarball.
2. It has to be the same compiler that was used to make your perl
executable. See the output of "perl -V". Then talk to your sysadmin about
getting the compiler you need installed.
3. Be patient. Most of the people on this list a
Tongue planted frimly in cheekok, so do this:
$qh = $dbh->prepare("blabla");
print "SQL is busy processing your query, please wait ...\n";
$qh->execute;
@results = $qh->fetchrow_array;
print "... Processing complete.\n";
The whole point of this is that TIMTOWTDI, but if you actually want to
Look at the output of your browser-run environment script. mod_perl IS installed.
And I'll bet dollars to donuts that Brett is right about DBI being loaded via a
mod_perl handler. Work with your sysadmin to get things installed in the right
places.
[EMAIL PROTECTED] wrote:
> On Wed, 8 Aug 2001
eeds to be changed to just DBI on the command line/cron, and I THINK it means
that DBI may need to be installed separately. Try "perl -MDBI -e'1'" to see if it is
actually installed.
jeff
[EMAIL PROTECTED] wrote:
> On Wed, 08 Aug 2001 12:51:53 -0400, Jeff Seger
> <[EMAI
There are three things to take into account hereenvironment, environment,
environment.
Your cron job needs to have the same environment as the web server.
something like this:
02 8 * * * . /dw/prod/DW/Load/config/dw-env.sh; /dw/prod/DW/Load/scripts/daily.pl
where /dw/prod/DW/Load/config/dw
If you are loading a large file to Informix and want to avoid the
overhead of doing many inserts, you can call dbaccess from a system call
and pipe commands to it (see below). Otherwise, you need to loop and
insert each row individually.
While I love DBI, doing inserts just isn't as fast as run
Are you sure what versions you have??
Richard Sutherland wrote:
> All,
>
> I am getting an ORA-01008 when using bind variables on Oracle7 instances,
> but not on Oracle8 instances. This has happened on both Unix and Linux
> OS's. Here is the error:
>
> DBD::Oracle::db prepare failed: ORA-010
41 matches
Mail list logo