From: "McMahon, Chris" <[EMAIL PROTECTED]>
> Hello again...
> I'm getting the hang of this, but now:
>
> $sql = qq{INSERT INTO table VALUES ($port,333,,,0);
While you could use
$sql = qq{INSERT INTO table VALUES ($port,333,NULL,NULL,0);
you should not do it this way.
First thing ... y
On Wed, 5 May 2004, McMahon, Chris wrote:
>
> Actually needs the text "NULL". "undef" doesn't work. Apologies-- I
> hope somebody else needs this information someday.
>
> $sql = qq{INSERT INTO table VALUES ($port,333,,,0); $sth =
Hi Chris, better/easier use this:
$SQL="INSERT INTO table(fiel
Actually needs the text "NULL". "undef" doesn't work. Apologies-- I
hope somebody else needs this information someday.
-Chris
-Original Message-
From: McMahon, Chris
Sent: Wednesday, May 05, 2004 2:23 PM
To: [EMAIL PROTECTED]
Subject: Another simp
Hello again...
I'm getting the hang of this, but now:
$sql = qq{INSERT INTO table VALUES ($port,333,,,0);
$sth = $dbh->prepare($sql)
or die "Could not prepare $sql\n";
$sth->execute()
or die "Could not execute $sql\n";
...fails with "Incorrect syntax near ','" error, b
McMahon, Chris wrote:
> Can anyone suggest DBI syntax to capture the result of
>
> SELECT DISTINCT column1 FROM table WHERE column2= -1
>
> into an array? Just a hint would help...
my @results = $dbh->selectcol_array('select ...');
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For
Hi Chris,
Try this:
#!/usr/bin/perl
# Purpose: Perl script for testing Oracle Database
Connection
# First setenvironmental variable
BEGIN {
# Comment ORACLE_HOME variable if running on
window
$ENV{ORACLE_HOME} = '/usr/orasys/8.1.7';
$ENV{TWO_TASK}= 'mydbname';
}
use strict;
nt: Wednesday, May 05, 2004 12:46 AM
||> To: [EMAIL PROTECTED]
||> Subject: Simple DBI question
||>
||>
||> Hello...
||> My first DBI script was simply an inventory of columns in
||> tables.
||> Now I'm struggling with my second DBI script, and finding the
||>
Hello...
My first DBI script was simply an inventory of columns in
tables.
Now I'm struggling with my second DBI script, and finding the
CPAN docs tough going.
Can anyone suggest DBI syntax to capture the result of
SELECT DISTINCT column1 FROM table WHERE column2= -1