name that mysql function!
Moderator: General Moderators
-
Charles256
- DevNet Resident
- Posts: 1375
- Joined: Fri Sep 16, 2005 9:06 pm
name that mysql function!
What the hell is the name of that mysql function that advances me to the next row without doing a query? it's just a simple little function but it's name escapes me for some damn reason...help?
- Buddha443556
- Forum Regular
- Posts: 873
- Joined: Fri Mar 19, 2004 1:51 pm
One of these?
Code: Select all
mysql_fetch_row();
mysql_fetch_assoc();
mysql_fetch_array();
mysql_fetch_object();
// ... and
mysql_data_seek();-
Charles256
- DevNet Resident
- Posts: 1375
- Joined: Fri Sep 16, 2005 9:06 pm
good job..i thought it was mysql_data_seek...code...
should return the second row,first entry, i.e. karts, however it's returning the first row that has scooters in it,the hell?
Code: Select all
$links="SELECT * FROM links";
$getlinks=mysql_query($links);
$link=mysql_fetch_array($getlinks);
mysql_data_seek($getlinks,2);
echo $link[0];-
Charles256
- DevNet Resident
- Posts: 1375
- Joined: Fri Sep 16, 2005 9:06 pm
i just did...
go multi-dimensional arrays.
Code: Select all
$links="SELECT * FROM links";
$getlinks=mysql_query($links);
$link=array();
while ($test=mysql_fetch_array($getlinks))
{
static $i=0;
for ($o=0;$o<4;$o++)
{
$link[$i][$o]=$test[$o];
}
$i++;
}Actually that should be returning the 3rd row. 0..1..2mysql_data_seek($getlinks,2);
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.