alejandro52 Posted May 27, 2007 Share Posted May 27, 2007 Is there any way to get data from a row without moving the pointer? Link to comment https://forums.phpfreaks.com/topic/53194-mysql-fetch-row-data-without-moving-the-pointer/ Share on other sites More sharing options...
AndyB Posted May 27, 2007 Share Posted May 27, 2007 Pointer? I thought pointers only applied to sequential data (like text files or tapes) not unordered and random access data. Am I missing something? Link to comment https://forums.phpfreaks.com/topic/53194-mysql-fetch-row-data-without-moving-the-pointer/#findComment-262817 Share on other sites More sharing options...
alejandro52 Posted May 27, 2007 Author Share Posted May 27, 2007 I mean when you use $row = mysql_fetch_row($result) it takes the first row and moves to the other one.when you use it again it does the same. I need to take some data from a row without moving the pointer to the next row. Link to comment https://forums.phpfreaks.com/topic/53194-mysql-fetch-row-data-without-moving-the-pointer/#findComment-262828 Share on other sites More sharing options...
AndyB Posted May 27, 2007 Share Posted May 27, 2007 Then mysql_fetch_array() or mysql_fetch_assoc() may be more appropriate for whatever you're doing. Either that or retrieve specific rows using the WHERE syntax. Link to comment https://forums.phpfreaks.com/topic/53194-mysql-fetch-row-data-without-moving-the-pointer/#findComment-262836 Share on other sites More sharing options...
Diego17 Posted May 27, 2007 Share Posted May 27, 2007 there's mysql_data_seek http://www.php.net/manual/en/function.mysql-data-seek.php Link to comment https://forums.phpfreaks.com/topic/53194-mysql-fetch-row-data-without-moving-the-pointer/#findComment-262844 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.