12.04.2016, 12:45
(
Last edited by SQLite; 13/04/2016 at 07:50 AM.
)
Hey Guys... i have a litle problem...
So, the following. I have a record ... this is not read correctly.
as you can see does not work the whole query ... but why?
Here is my Code:
So, the following. I have a record ... this is not read correctly.
as you can see does not work the whole query ... but why?
Here is my Code:
PHP Code:
public LoadBizz()
{
new
DBResult:dbresult = db_query(ServerDB, "SELECT * FROM `Bizz`"),
rows = db_num_rows(dbresult),
field[20],
time = GetTickCount();
if(!rows) {
return print("Es wurden keine Bizz in der Datenbank gefunden!");
}
for(new i=0; i<rows; i++) {
db_get_field_assoc(dbresult, "BizzID", field, sizeof(field)); bInfo[i][ID] = strval(field);
db_get_field_assoc(dbresult, "Name", field, sizeof(field)); bInfo[i][Name] = strval(field);
db_get_field_assoc(dbresult, "Kasse", field, sizeof(field)); bInfo[i][Kasse] = strval(field);
db_get_field_assoc(dbresult, "PickupX", field, sizeof(field)); bInfo[i][X] = strval(field);
db_get_field_assoc(dbresult, "PickupY", field, sizeof(field)); bInfo[i][Y] = strval(field);
db_get_field_assoc(dbresult, "PickupZ", field, sizeof(field)); bInfo[i][Z] = strval(field);
CreateBizzPickup(i, bInfo[i][Name], bInfo[i][X], bInfo[i][Y], bInfo[i][Z]);
printf("BizzID: ", bInfo[i][ID]);
printf("Bizz Name: ", bInfo[i][Name]);
printf("Bizz Kasse: ", bInfo[i][Kasse]);
printf("BizzX: ", bInfo[i][X]);
printf("BizzY: ", bInfo[i][Y]);
printf("BizzZ: ", bInfo[i][Z]);
db_next_row(dbresult);
}
db_free_result(dbresult);
printf("Es wurden %d Businesse in %dms geladen!", rows, GetTickCount()-time);
return 1;
}