Jump to content
php.lv forumi

random id no mysql


Vebers

Recommended Posts

mysql_query("SELECT banneri.adrese, lietotaji.id, lietotaji.categorie FROM banneri, lietotaji WHERE lietotaji.id='$id' AND banneri.cat=lietotaji.categorie");

 

kaa lai izvelk no mysql bannera datus ar random "banneri.id", tjip kaa ar php funkciju rand, bet ieprieksh nav zinaams kaadi "id" ir datubazee.

Link to comment
Share on other sites

kops kuras mysql versijas tad RAND() darbojas ?

man vinsh k-kaa negrib darboties.. visu laiku izvelk pirmo ierakstu.

 

P.S. pashreizeeja mysql versija : 3.23.54-nt

serveris nav mans! tapec jaunaku mysql ari nevaru uzlikt

Edited by MakaTaNaw
Link to comment
Share on other sites

×
×
  • Create New...