Powered by Ajaxy
Digg StumbleUpon LinkedIn YouTube Flickr Facebook Twitter RSS Reset

Perl: Use DBI to connect to a Microsoft Access database

Perl: Use DBI to connect to a  Microsoft Access database
{filelink=14654}

#!c:/perl/bin
use DBI;
use strict;
# Create a connection to MS ACCESS(.mdb)
 my $db_connect = DBI->connect("dbi:ODBC:Test");
my $Query="SELECT FirstName, LastName FROM Users";
my $statement = $db_connect->prepare($Query);
$statement->execute
	|| die "Cannot execute this query";
# Fetch a result row as an associative array
while (my @row=$statement->fetchrow_array)
{
   print "@row ";
}
$statement->finish();
# Close the connection
$db_connect->disconnect();

Users who found this page were searching for:

  • perl ms access
  • how to use java to write Nonagon
  • java limit digits
  • python read a given line of a file
  • PERL MS ACCESS CONNECT
  • how to align text output in java
  • python dictionary values list
  • python program that reads a complete file line by line
  • perl access 2010 connect
  • perl dbi msaccess

No comments yet.

Leave a Comment