On dom, 2007-01-28 at 18:51 -0500, nitrox . wrote:
> I took the quotes off. I thought that quotes around numbers was wrong also. 

Quotes are no necessary around numeric values, but they aren't wrong
neither, simply optional.

> I added the error checking and this is the error:
> 
> Could not perform query : You have an error in your SQL syntax; check the 
> manual that corresponds to your MySQL server version for the right syntax to 
> use near '' at line 1

Try with the new code I sent you too see the query you're sending,
probably -but not sure- $user_id is void and you're doing:

SELECT * FROM inf_member WHERE user_id=

Anyway if you can see the query, you'll see the source of the error.

> 
> and this is the code again:
> 
> <?php
> include("db.php");
>         $result = mysql_query("SELECT * FROM inf_member WHERE 
> user_id=$user_id");
>         if ( ! $result ) {
>               die ("Could not perform query $query: ".mysql_error()."\n");
>       }
> 
>               while($myrow = mysql_fetch_assoc($result))
>               {
>                      echo "<b>";
>                      echo $myrow['user_name'];
>                      echo "</b>";
>                      echo $myrow['rank'];
>                                        echo "</b>";
>                      echo $myrow['country'];
>                                        echo "</b>";
>                      echo $myrow['email'];
>                      echo "</b>";
>                      echo $myrow['quote'];
>                      echo "</b>";
>                      echo $myrow['config'];
>                                        echo "</b>";
>                                        echo $myrow['map'];
>                      echo "</b>";
>                      echo $myrow['gun'];
>                      echo "</b>";
>                      echo $myrow['brand'];
>                                        echo "</b>";
>                                        echo $myrow['cpu'];
>                                        echo "</b>";
>                      echo $myrow['ram'];
>                      echo "</b>";
>                      echo $myrow['video'];
>                      echo "</b>";
>                      echo $myrow['sound'];
>                                        echo "</b>";
>                                        echo $myrow['monitor'];
>                      echo "</b>";
>                      echo $myrow['mouse'];
>                      echo "</b>";
>                      echo $myrow['brand'];
>                                        echo "</b>";
> 
>              }
> ?>
> 
> _________________________________________________________________
> Laugh, share and connect with Windows Live Messenger 
> http://clk.atdmt.com/MSN/go/msnnkwme0020000001msn/direct/01/?href=http://imagine-msn.com/messenger/launch80/default.aspx?locale=en-us&source=hmtagline
> 

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to