#1

this is for get how much rows are in one table right?
pawn Код:
mysql_query("SELECT NULL FROM table1");
mysql_store_result();
new rows = mysql_num_rows();
mysql_free_result();
 
printf("There are %d rows in table1",rows);
so how i can get wirh this code how much rows have the lettere a ? or the id 1
Reply
#2

pawn Код:
mysql_query("SELECT NULL FROM table1 WHERE somefield1 LIKE 'a' ");
The code above will search all rows of data where the field name is 'somefield1' and where the row content is just 'a', the query won't select any data, the only thing you can do is mysql_num_rows (seeing as you're selecting NULL).
Reply
#3

thx you
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)