Re: Thanks but problem Again! (MySQL & PHP database script PLEASE)

From: Date: Fri, 22 Oct 2004 08:13:48 +0000
Subject: Re: Thanks but problem Again! (MySQL & PHP database script PLEASE)
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-200068@lists.php.net to get a copy of this message
Ramil Sagum wrote:
On Fri, 22 Oct 2004 16:13:07 +0900, Sugimoto <sugimoto@momat.go.jp> wrote:
Thank you for two of you.
dou itashimashite. This is your problem:
Bad query: You have an error in your SQL syntax near 'and Tit like and Aut like and Auty like ' at line 4
The SQL query you formed may have an invalid syntax. Dakara, $result does not contain a valid MySQL resource. Mochiron, next operations with $result will produce errors:
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result... Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result....
What you can do is to debug first your SQL statement: $sql = "select * from gen_table where GO like ". $_GET["go"]. " and ym like ". $_GET["dt"] . " and Tit like ".$_GET["ti"]." . " and Aut like ".$_GET["au"]. " and Auty like ".$_GET["ay"]; print_r($sql); //show the SQL statement, (remove this when everything is working) $result = mysql_query($sql); print_r to var_dump ha php de debug no ni yaku ni tachimasu! ---- ramil http://ramil.sagum.net and now in english...? I don't think I understood even half of what you said... what does "ha php de debug no ni yaku ni tachimasu" mean? or "dou itashimashite" not to mention "dakara" and "mochiron"


« previous php.general (#200068) next »