hello there i am new to all of this and i trying to display recods from the database i have created and i am having errors [code] <? //connect to mysql $db_gigs=mysql_connect("localhost","web22-XXX","XXX if (!$db_gigs) { // db error function echo db_error("$db_gigs"); die(); } //select which database you want to edit mysql_select_db("gigs"); //select the table $result = mysql_query("select * from gigs"); //grab all the content while($r=mysql_fetch_array($result)){ //the format is $variable = $r["nameofmysqlcolumn"]; $id=$r["id"]; $event=$r["event"]; $venue=$r["venue"]; $date=$r["date"]; $rating=$r["rating"]; //display the row echo "$id <br> $event <br> $venue <br> $date | $rating <br />"; } ?>[/code] Thats what i have now and i am getting a error which says [quote]Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/sites/reesweb.co.uk/public_html/mattbay/music.php on line 38[/quote] Any ideas thanks Matthew