Dear All:

I have the following code in my program, which I use to transfer data from some webpages to an Access table,

$sqlinsert="INSERT INTO $Table[$II] VALUES ('$ID','$Itemname','$Firstb +id','$Endingprice')"; $rc=$db->Sql($sqlinsert); die qq(SQL fail "$rc":), $db->Error(),qq(n) if $rc;

To some webpages, I got the following error message,

SQL fail "1":-3100[Microsoft][ODBC Microsoft Access Driver] Syntax err +or (missing operator) in query expression '' 1800's HAND EMBROIDERED +MOTTO [I SLEPT...] NR ','US $9.95','>US $36.72')'.10n at H:\strategy +trying.pl line 258, <INP> chunk 21.

What looks weird to me is that to some webpages, I do not get the error message. And the data can be transfered to the Access table.

Can anybody tell me what the problem is? Thank you in advance.....luoina

20040220 Edit by Corion: Added formatting

20040220 Edit by BazB: Changed title from 'Why I got this error message?'


In reply to MS Access/ODBC error: why?? by luoina

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.