View Single Post
  #2 (permalink)  
Old 2006-06-16, 12:20 PM
Deus_m1k3 Deus_m1k3 is offline
Junior Member
 
Join Date: Nov 2004
Posts: 13
Deus_m1k3
Default

As far as I can read everithin' I think it's ok, but why don't U try another approach??

$conection= @mysql_connect($server,$user,$pass) or die("Error [0.0]: ". mysql_error()." <br>");
@mysql_select_db($database,$conection) or die("Error [0.1]: ". mysql_error());

$sql_ins = "INSERT INTO student4 VALUES ('', "zubair", "second", 500)";
mysql_query ($sql_ins) or die ("Error [1]: ".mysql_error ());

or

$sql_ins = "INSERT INTO student4 VALUES (, "zubair", "second", 500)";
mysql_query ($sql_ins) or die ("Error [1]: ".mysql_error ());

If the id field is auto_incremet & also PK you shouldn't force it to NULL it'll create inconsistent data, hope this could help

READ YA
Reply With Quote