Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Comment on

( #3333=superdoc: print w/ replies, xml ) Need Help??
Hello! Here is what I am trying to do. I want users of my website to sign my guestbook which has to textarea fields for comments. What I have come to realize is that when I post more than around 256 characters into a Memo field in an MS Access database, it doesn't insert anything (no record at all). There was a similar post a looong time ago but it doesn't sound like there was any definite solution. I know most people will not be using MS Access, but surely someone else has needed to use it and come across this problem. For your reference, the previous post was: http://www.perlmonks.com/index.pl?node_id=39296&lastnode_id=3989 Now, for my code:
#!/usr/bin/perl use strict; use CGI::Carp qw(fatalsToBrowser); use CGI qw(:all); use CGI; use DBI; my $myCGI = new CGI; print "Content-type: text/html\r\n\r\n"; my $name = $myCGI->param('txtName'); my $email = $myCGI->param('txtEmail'); my $country = $myCGI->param('txtCountry'); my $website = $myCGI->param('txtWebsite'); my $publicmessage = $myCGI->param('txtPublic'); my $privatemessage = $myCGI->param('txtPrivate'); my $dbh = DBI->connect('DBI:ODBC:whatever', 'whatever', 'whatever'); #$dbh->do("set textsize 25000"); #$dbh->{LongReadLen} = 50000; #$dbh->{LongTruncOk} = 1; my $sth = $dbh->prepare(q{ INSERT INTO tblGuestbook (name, email, country, website, publicmessage, privatemessage, IP) values (?,?,?,?,?,?,?) }); $sth->execute($name,$email,$country,$website,$publicmessage,$privateme +ssage,$ENV{REMOTE_ADDR}); $sth->finish; $dbh->disconnect;
Notice the three commented fields which I have tried to use with no luck. I would greatly appreciate any comments (and code!) from anyone who has a solution to this. Thank you! Andrew

In reply to Cannot insert into MS Access Memo field with DBI by drewbert2000

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!
  • 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, 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, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • Outside of code tags, you may need to use entities for some characters:
            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.
  • Log In?
    Username:
    Password:

    What's my password?
    Create A New User
    Chatterbox?
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others cooling their heels in the Monastery: (10)
    As of 2014-08-22 22:01 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      The best computer themed movie is:











      Results (168 votes), past polls