retriving real values from mysql instead of resource id's
Posted: Tue May 18, 2004 7:39 pm
hey, i was wondering how to get a real value from a mysql database without just retriving a resource id. For example, a script like this:
will give me a result like "Resource ID#1", when what i really want is the value that is stored in the database. what am I doing wrong and how to I access things in the database?
Code: Select all
<?php
include ('mysql_connect.php');
$get_money = "SELECT money FROM stats WHERE user_id = $userid" ;
$money = @mysql_query ($get_money);
echo "$money";
?>