If you want to parse the results using a single loop, the following approach is an option. The important part here is that you need an ORDER BY clause in your statement and appropriate changes in the script, to make your loop work.
A simplified example, based on the code in the question:
$result1 = mysqli_query($conn, "SELECT * FROM bundel ORDER BY BundelName");
$bundel = "";
while ($row = mysqli_fetch_assoc($result1)) {
if ($bundel != $row["BundelName"]) {
echo "<table>";
echo '<tr><td>' . $row['BundelName'] . '</td></tr>';
};
echo '<tr>';
echo '<td>' . $row['Description'] . '</td>';
echo '<td>' . $row['SalesPrice'] . '</td>';
echo '</tr>';
if ($bundel != $row["BundelName"]) {
echo "</table>";
$bundel = $row["BundelName"];
};
}
Of course, you can group and store the result set in an array using BundelName as key, and print the expected output using another loop:
$stmt = mysqli_query($conn, "SELECT * FROM bundel");
$result = array();
while ($row = mysqli_fetch_assoc($stmt)) {
$result[$row["BundleName"]][] = array(
"Description" => $row["Description"],
"SalePrice" => $row["SalePrice"]
);
}
foreach ($result as $bundel => $products) {
echo "<table>";
echo '<tr><td>' . $bundel . '</td></tr>';
foreach ($products as $product) {
echo '<tr>';
echo '<td>' . $product["Description"] . '</td>';
echo '<td>' . $product["SalePrice"] . '</td>';
echo '</tr>';
}
echo"</table>";
}