While I don't have the solution to your problem, I take the opportunity to comment on some strange things you use in your code:
$dbh = CreateObject OLE "ADODB.Connection" or die "Can't create connec +tion to DataBase: $!" unless $dbh;
In this statement you create the OLE object, or if that fails, you die with a message UNLESS it did not fail...Read that again... You want to remove the unless $dbh

Another thing is this:
$rs = $dbh->Execute( $sqlstatement ) or die print ( "Can't adminmail d +atabase problemdsds Perl says $!, DBI says ",$dbh::errstr,"");
Why do you do a die print? All other die statements you use have just the text as a parameter, and you now you're printing it explicitly. Besides that I don't know if that would work (it may, it's perl after all), you could just remove the print and the parens (), and it should all work.

Last question is why you are not using DBI? If you change to another ISP that uses MS SQL Server, or MySQL, you would have to change your code again. With DBI (and more specifically, using the ODBC or ADO DBD-driver) you would have the ability to write portable code. It would prevent you from rewriting your code over and over again.

Just my $0.02

--HolyGrail

In reply to Re: Need help with MS Access with Perl....... by holygrail
in thread Need help with MS Access with Perl....... by sprakash

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.