$inseq = 598;
$delSql = "DELETE FROM libname.tablename WHERE inseq=?";
$stmt = db2_prepare($conn,$delSql);
$res = db2_execute($stmt,array($inseq));
if(!$res)
{
throw new Exception(db2_stmt_errormsg(), db2_stmt_error());
} else {
$rows = db2_num_rows($stmt);
if ($rows > 0) {
echo "成功!从 libname.tablename 中删除了 ".$inseq." 条记录: 行数=".$rows;
} else {
echo "在 libname.tablename 中未找到要删除的行";
}
}