|
Posted by Christopher Pomasl on 10/02/45 11:34
On Sun, 11 Dec 2005 13:01:28 -0800, cover wrote:
> On Sun, 11 Dec 2005 18:15:52 GMT, Oli Filth <catch@olifilth.co.uk>
> wrote:
>
>>
>>Just tried a 34-field insert; it worked fine.
>
> Hmmm. Guess I'll keep looking for an error.
>
>>
>>What is your query string?
>>
>
> $sqlquery = "INSERT INTO $table VALUES('$id', '$etype', '$area',
> '$equipname', '$jdeno', '$equipno', '$mccloc', '$bspec', '$bsize',
> '$bfpm', '$gbmanu', '$lube', '$gbsize', '$gbratio', '$motorsize',
> '$motorframe', '$drivesprocket', '$drivensprocket', '$chainsize',
> '$lacingtype', '$brgtypesize', '$brgqty', '$tbrgtypesize', '$tbrgqty',
> '$headsize', '$hoawidth', '$tailsize', '$toawidth', '$cbsize',
> '$keysize' '$uhmwsize', '$convnotes',)";
>
> $results = mysql_query($sqlquery);
Someone already noted the extra comma at the end before the close paren.
You are also, seemingly, missing a comma between keisize and uhmwsize in
the last line.
Also take heed about the unescaped variables, if that is the case.
Someone savvy enough could all sorts of fun stuff to your SQL execution.
I also always print the error along with the error SQL in the event of an
error. If the user gets it on their page, well, they weren't going
anywhere anyway and you have the diagnostics when they complain!!
Chris
Always remember, you are unique...just like everyone else.
Navigation:
[Reply to this message]
|