jweavers
New Member
- Messages
- 11
- Reaction score
- 0
- Points
- 1
This is my sample code to check, whether database inserted into table or not.
Above code prints Records added to the database but, when I'm verifying those value in phpMyAdmin, then table always shows 0 rows selected. I don't know, where those values got inserted. It's not even showing any error. Please help me.
Code:
<?php include('db.php');
if ($bd) {
$SQL = "INSERT INTO test(name) VALUES('ravi')";
$result = mysql_query($SQL,$bd);
mysql_close($bd);
print "Records added to the database";
print $result;
}
else
{
print "Database NOT Found ";
mysql_close($bd);
}
?>
Above code prints Records added to the database but, when I'm verifying those value in phpMyAdmin, then table always shows 0 rows selected. I don't know, where those values got inserted. It's not even showing any error. Please help me.