Kann man diesen Code irgendwie kleiner machen? Bzw. Schlauer?
new sql1[150],sql2[150],sql3[150],sql4[150],sql5[150],sql6[150],sql7[150],
sql8[150],sql9[150],sql10[150],sql11[150],sql12[150],sql13[150],sql14[150],sql15[150],
sql16[150],sql17[150],sql18[150],sql19[150],sql20[150],sql21[150],sql22[150],sql23[150],
sql24[150],sql25[150],sql26[150],sql27[150],sql28[150],sql29[150],sql30[150];
format(sql1, sizeof(sql1), "UPDATE hauser SET Mieter1 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql1);
format(sql2, sizeof(sql2), "UPDATE hauser SET Mieter2 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql2);
format(sql3, sizeof(sql3), "UPDATE hauser SET Mieter3 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql3);
format(sql4, sizeof(sql4), "UPDATE hauser SET Mieter4 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql4);
format(sql5, sizeof(sql5), "UPDATE hauser SET Mieter5 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql5);
format(sql6, sizeof(sql6), "UPDATE hauser SET Mieter6 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql6);
format(sql7, sizeof(sql7), "UPDATE hauser SET Mieter7 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql7);
format(sql8, sizeof(sql8), "UPDATE hauser SET Mieter8 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql8);
format(sql9, sizeof(sql9), "UPDATE hauser SET Mieter9 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql9);
format(sql10, sizeof(sql10), "UPDATE hauser SET Mieter10 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql10);
format(sql11, sizeof(sql11), "UPDATE hauser SET Mieter11 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql11);
format(sql12, sizeof(sql12), "UPDATE hauser SET Mieter12 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql12);
format(sql13, sizeof(sql13), "UPDATE hauser SET Mieter13 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql13);
format(sql14, sizeof(sql14), "UPDATE hauser SET Mieter14 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql14);
format(sql15, sizeof(sql15), "UPDATE hauser SET Mieter15 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql15);
format(sql16, sizeof(sql16), "UPDATE hauser SET Mieter16 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql16);
format(sql17, sizeof(sql17), "UPDATE hauser SET Mieter17 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql17);
format(sql18, sizeof(sql18), "UPDATE hauser SET Mieter18 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql18);
format(sql19, sizeof(sql19), "UPDATE hauser SET Mieter19 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql19);
format(sql20, sizeof(sql20), "UPDATE hauser SET Mieter20 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql20);
format(sql21, sizeof(sql21), "UPDATE hauser SET Mieter21 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql21);
format(sql22, sizeof(sql22), "UPDATE hauser SET Mieter22 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql22);
format(sql23, sizeof(sql23), "UPDATE hauser SET Mieter23 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql23);
format(sql24, sizeof(sql24), "UPDATE hauser SET Mieter24 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql24);
format(sql25, sizeof(sql25), "UPDATE hauser SET Mieter25 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql25);
format(sql26, sizeof(sql26), "UPDATE hauser SET Mieter26 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql26);
format(sql27, sizeof(sql27), "UPDATE hauser SET Mieter27 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql27);
format(sql28, sizeof(sql28), "UPDATE hauser SET Mieter28 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql28);
format(sql29, sizeof(sql29), "UPDATE hauser SET Mieter29 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql29);
format(sql30, sizeof(sql30), "UPDATE hauser SET Mieter30 = '-' WHERE ID = '%d'", HausIDErstellen);
mysql_query(sql30);