abhishekmat
01-26-2006, 08:07 AM
This is the error:
Parse error: syntax error, unexpected ',', expecting T_PAAMAYIM_NEKUDOTAYIM in c:\Inetpub\wwwroot\edu\database.php on line 11
I have already create a table "abhi1" with all the fields.
If am typing
INSERT INTO abhi1 values('','sa','as','ss','ss','e','r','tt','tt','yy','uu','ii','i','o','p','u','t','r','e','w','q','q','q','q','q','q');
on mysql prompt it is working fine
This is the CODE:
<?php
$conn=mysql_connect("localhost", "root", "");
mysql_select_db("abhishek", $conn);
$sql = "INSERT INTO abhi1 values('','sa','as','ss','ss','e','r','tt','tt','yy','uu','ii','i','o','p','u','t','r','e','w','q','q','q','q','q','q')";
$result = mysql_query(&sql, $conn) or die(mysql_error());
echo $result;
?>
This is my forst try on PHP :)
I think all are well aware of PHP here and I will get enough advice to make it work:)
Thanks in advance
Parse error: syntax error, unexpected ',', expecting T_PAAMAYIM_NEKUDOTAYIM in c:\Inetpub\wwwroot\edu\database.php on line 11
I have already create a table "abhi1" with all the fields.
If am typing
INSERT INTO abhi1 values('','sa','as','ss','ss','e','r','tt','tt','yy','uu','ii','i','o','p','u','t','r','e','w','q','q','q','q','q','q');
on mysql prompt it is working fine
This is the CODE:
<?php
$conn=mysql_connect("localhost", "root", "");
mysql_select_db("abhishek", $conn);
$sql = "INSERT INTO abhi1 values('','sa','as','ss','ss','e','r','tt','tt','yy','uu','ii','i','o','p','u','t','r','e','w','q','q','q','q','q','q')";
$result = mysql_query(&sql, $conn) or die(mysql_error());
echo $result;
?>
This is my forst try on PHP :)
I think all are well aware of PHP here and I will get enough advice to make it work:)
Thanks in advance