27 messages in com.mysql.lists.mysqlRE: insert data | From | Sent On | Attachments |
|---|---|---|
| Gerald Preston | 27 Feb 2005 03:02 | |
| Logan, David (SST - Adelaide) | 27 Feb 2005 03:08 | |
| Gerald Preston | 27 Feb 2005 03:12 | |
| Gerald Preston | 27 Feb 2005 03:38 | |
| Logan, David (SST - Adelaide) | 27 Feb 2005 03:48 | |
| Gerald Preston | 27 Feb 2005 04:00 | |
| John Doe | 27 Feb 2005 04:36 | |
| Gerald Preston | 27 Feb 2005 13:18 | |
| Logan, David (SST - Adelaide) | 27 Feb 2005 13:27 | |
| Gerald Preston | 27 Feb 2005 14:10 | |
| Logan, David (SST - Adelaide) | 27 Feb 2005 14:13 | |
| Paul DuBois | 27 Feb 2005 14:46 | |
| John Doe | 27 Feb 2005 15:42 | |
| Michael Stassen | 28 Feb 2005 07:28 | |
| Michael Stassen | 28 Feb 2005 10:17 | |
| Gerald Preston | 28 Feb 2005 13:19 | |
| William R. Mussatto | 28 Feb 2005 13:24 | |
| Eamon Daly | 28 Feb 2005 14:02 | |
| Gerald Preston | 28 Feb 2005 15:39 | |
| John Doe | 28 Feb 2005 15:47 | |
| Logan, David (SST - Adelaide) | 28 Feb 2005 16:09 | |
| Gerald Preston | 03 Mar 2005 23:59 | |
| Roger Baklund | 04 Mar 2005 06:21 | |
| John Trammell | 04 Mar 2005 12:48 | |
| Michael Stassen | 04 Mar 2005 14:51 | |
| Michael Stassen | 04 Mar 2005 15:41 | |
| Gerald Preston | 05 Mar 2005 02:19 |
| Subject: | RE: insert data ![]() |
|---|---|
| From: | Logan, David (SST - Adelaide) (davi...@hp.com) |
| Date: | 02/27/2005 03:08:20 AM |
| List: | com.mysql.lists.mysql |
Hi Gerald,
If this is copied out of your perl code then you haven't put anything into the $sql variable. Try uncommenting the 2 lines above.
Regards
David Logan Database Administrator HP Managed Services 148 Frome Street, Adelaide 5000 Australia
+61 8 8408 4273 - Work +61 417 268 665 - Mobile +61 8 8408 4259 - Fax
-----Original Message----- From: Gerald Preston [mailto:jw...@ont.com] Sent: Sunday, 27 February 2005 9:33 PM To: mysql users Subject: insert data
Hi!
I am trying to insert data for the first time using MySQL. In Oracle I used the following:
# my $sql = "insert into bar( group_name, me, daily, item, unit, qty, amount, tax, total )
# values( ?, ?, ?, ?, ?, ?, ?, ?, ? ) ";
my $sth = $dbh->prepare( $sql );
die $dbh->errstr if $dbh->err;
$sth->execute( $group_name, $me, $daily, $item, $unit, $qty, $amount, $tax, $total ) || die "Cannot execute FIRST Statement!!\n$DBI::errstr";
I keep getting "Can't call method "prepare" on an un undefined value. All the name listed are correct by looking at MySQLAdmin1.3\4.
Any ideas?
Thanks,
Jerry




