Hi,
>Row = mysql_fetch_row(result); <-------- Here is the problem
That syntax seems correct. Make sure you have defined Row as:
MYSQL_ROW Row;
and that result is defined as
MYSQL_RES *result;
printf("\n\t%u %4s",j,Row); <-------YOUR problem seems to be here! change
Row to Row[0] and see if that works!
Regards
Jorge
MySQL Development Team
__ ___ ____ __ __
/ |/ /_ __/ __/ __ \/ / Jorge del Conde <[EMAIL PROTECTED]>
/ /|_/ / // /\ \/ /_/ / /__ MySQL AB, http://www.mysql.com/
/_/ /_/\_, /___/\___\_\____/ Mexico City, Mexico
<___/
----- Original Message -----
From: "Gonzalo Aguilar" <[EMAIL PROTECTED]>
To: "lista MySQL" <[EMAIL PROTECTED]>
Sent: Wednesday, January 24, 2001 6:39 PM
Subject: mysql_fetch_row blocks my computer...
> First of all, before I forget it...
> My MySQL is:
> mysql Ver 9.38 Distrib 3.22.32, for pc-linux-gnu (i686)
>
> I have a problem with mysql_fetch_row...
> When I use it the system goes to 100% CPU usage and nothing else, I get
> not
> rows...
> The code is:
> ********************************************
> .
> .
> .
>
> Row = mysql_fetch_row(result); <-------- Here is the problem
> j=0;
> while(Row!=NULL);
> {
> printf("\n\t%u %4s",j,Row);
> Row=mysql_fetch_row(result);
> j++;
> }
> .
> .
> .
> ********************************************
> I know result contains a valid address, because I use it to show how
> many
> rows are available, (42 rows) but the system blocks anyway until I press
> Ctrl-c
>
> The program waits before j=0;
>
> Any points on this...?
>
> Thank you
>
> Answer to my e-mail too, thanks...
>
> --
> Gonzalo Aguilar. Madrid, España (Spain) |
> Reymad Studios | [EMAIL PROTECTED] |
> Privado | [EMAIL PROTECTED] |
> ----------------------------------------+
>
> ---------------------------------------------------------------------
> Before posting, please check:
> http://www.mysql.com/manual.php (the manual)
> http://lists.mysql.com/ (the list archive)
>
> To request this thread, e-mail <[EMAIL PROTECTED]>
> To unsubscribe, e-mail
<[EMAIL PROTECTED]>
> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php