beginTransaction(); $update_log = date("Y-m-d H:i:s") . " - " . $_SESSION["name"] . " " . $update_log . " "; // checkstep 업데이트 쿼리 $sql = "UPDATE $DB.$tablename SET checkstep = ?, update_log =? WHERE num = ? LIMIT 1"; $stmh = $pdo->prepare($sql); $stmh->execute([$checkstep, $update_log, $num]); // 커밋 $pdo->commit(); echo json_encode(['success' => true, 'checkstep' => $checkstep]); } catch (PDOException $Exception) { // 롤백 및 에러 메시지 반환 $pdo->rollBack(); echo json_encode(['error' => $Exception->getMessage()]); exit; } } ?>