First you will need to check if the record is already there
assuming FuelCrd is the unique value in the table (cardlock)
'SELECT FuelCrd FROM cardlock WHERE FuelCrd = $FuelCrd';
if the SELECT does return a value then the record is there.
In this case you will need issue an UPDATE statement
'UPDA
use this querry
'update tablename set fieldname1=newvalue1,fieldname2=newvalue2 where
somefield=something'
- Original Message -
From: "Scott Taylor" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, October 31, 2002 9:34 PM
Subject: SQL table updates
> Hello all,
>
> Can
At 08:06 AM 10/31/02, you wrote:
One way.
? Of the 3 fields which is unique field..I'll assume FuelCrd..
after ..print "$FuelCrd, $TrkID, $FuelCmp\n"; .insert
this
my ($check) = $dbh->selectrow_array ("SELECT fuelCrd FROM cardlock WHERE
fuelCrd = ?", undef,$F