http://www.perlmonks.org?node_id=1128168


in reply to Re: How can I import text to Access
in thread How can I import text to Access

I also tried this one just now, and I get an error saying my DevComm1. +mdb file is not found. It does exist in the folder location I specifi +ed. #!perl use strict; use warnings; use DBI; print 'bits: ' . (8 * (length pack 'P', -1)) . "\n\n"; my $DBFile = q(W:\Glenn-123456\Test\DevComm1.mdb); my $dbh = DBI->connect("dbi:ODBC:Driver={Microsoft Access Driver (*.md +b)};DBQ=$DBFile",'','') or die("cannot connect to DB"); my $SQLquery = "SELECT * INTO [Input] FROM [Text;DATABASE=W:\Glenn-123 +456\Test\\VDD\Data\;HDR=No].[DevComm1.txt]"; my $sth = $dbh->prepare($SQLquery); my $rc = $sth->execute; #Trying again