Hmm, run it manually? I'm a newbie, so, could you explain how I'd do that?
"Jason Murray" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
I'd say $id is blank, not being passed in, or is equal to a
Maybe you should echo out your SQL and run it manually to see
what's going on.
Web Developer, Melbourne IT
"Work now, freak later!"
> -----Original Message-----
> From: Dr. Shim [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, April 02, 2002 2:41 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Variable Appended To The End of a URL Is Not Working in
> SQL Query
> I have a variable which is appeneded to the end of a URL, like
> This would return "your_value";
> echo $your_variable;
> But this wouldn't work, and returns an error
> $sql = "SELECT * FROM fldField WHERE IDField = " . $id;
> What could possibly be wrong? If you need more info, then
> tell me. Here's my
> $db = @odbc_connect('ReviewDatabase', 'root', '') or exit)("Error
> $sql = "SELECT * FROM tblArt WHERE IDArt = $id";
> $cursor = @odbc_exec($db, $sql) or exit ("Error
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php