PHP-DB Mailing List
Hello Jonathan,
--
Friday, March 29, 2002, 12:16:19 PM, you wrote:


> It should be:

>   $sql = "Insert into table ('$field1','$field2',....,'$field61')";
>   mysql_query($sql) or die(msql_error());

Thanks that is helpful.


> It's a little easier to read and understand. Note that you don't really have
> to do anything special to be able to separate the query onto multiple lines:

>   $sql = "INSERT INTO
>   table
>   SET
>   field='value',
>   field2='value';
>   ";

>   mysql_query($sql) or die(msql_error());

I re coded as per the suggestion above.  Still, I get a new error
message,

"You have an error in your SQL syntax near " at line 55."


Line 55 is R38='$R38',



> ... will work fine. No need for special characters - PHP will recognize
> values and strings that are on multiple lines AS LONG AS the value starts
> and ends with quotes (and the semicolon at the end).
>   field2='value';
>   ";


Any suggestions.....

Jerry


-- 
Ethan J. Mings
Office E-mail [EMAIL PROTECTED]


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to