I agree what David says. but the point is if someone else moved the pointer using mysql_data_seek($i) and he didn't tell me how much $i is, or I use mysql_data_seek so many times that I can't remember the sum of the offsets. I don't think write a tracker is a feasible way, because there are so many actions can move pointer, mysql_data_seek(), mysql_fetch_row(), mysql_fetch_array() etc. Tracking all these actions is not possible, and it is error-prone and needs much much effort. "David Robley" <robleyd@ozemail.com.au> ??????:MPG.19a61bea53540864989814@news.php.net... > In article <20030811093307.75301.qmail@pb1.pair.com>, pengch@bizsmooth.com > says... > > in php,mysql_seek can move the pointer, but you have no way to know where > > the pointer locates currently. > > i think some function should be added in the future version, like > > mysql_getPointerPosition($rs) which returns a int as the position in > > resultset. so it's would be easy to implements some pointer moving functions > > like mysql_movenext(), mysql_moveprev,mysql_movefirst,mysql_movelast etc. > > It's trivial to do your own tracking of where the pointer is, using > mysql_num_rows to determine the number of rows in your result set and a > counter to track your movement, using mysql_data_seek, in the result set. > > The manual shows n example of how to return a set in reverse order, for > example. > > -- > Quod subigo farinam > > $email =~ s/oz$/au/o; > A: Because it messes up the order in which people normally read text. > Q: Why is top-posting such a bad thing? > A: Top-posting. > Q: What is the most annoying thing on usenet? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php