I for one don't understand what you are talking about. Maybe it is because English isn't my first lanuage...
You may want to try talking Perl instead of English, i.e. show us the code you have prepared in an attempt to do whatever you are trying to do.
-
$dbh = DBI->connect('dbi:mysql:dbname,user, pass);
#prepare and execute SQL statement
$sqlstatement="SELECT reg_id, category_id, category_name FROM table1 where category_id = \'$category_id\' ";
$sth = $dbh->prepare($sqlstatement);
$sth->execute ||
die "Could not execute SQL statement ... maybe invalid?";
print "<table border = 0>";
print "<td><p align=\"center\"><b>Reg ID</b></td>";
print "<td><p align=\"center\"><b>Category ID</b></td>";
print "<td><p align=\"center\"><b>Category Name</b></td>";
print "<tr>";
#output database results
while (@row=$sth->fetchrow_array)
{
my $query = "UPDATE table2 set category_name = \"$row[2]\" where reg_id = \"$row[0]\" ";
}
table1 having 100 records
the category_name under table2 are empty I wanted to fill this empty column with the value table1 under category_name would be placed using the condition of reg_id both table have same common entry.
Thanks