When I first started writing CGI code on Windows machines, the only way to talk to ODBC databases was with David Roth's Win32::ODBC module. (No, not that David Roth!) It provides a very easy-to-use interface to any ODBC-compliant database, such as Access, MS SQL Server, or any of the numerous other databases that run on the Windows platforms.
The way to do things now is DBI - the Perl database interface. DBI is database independent, so that you can write code once, and run it on any database. There will be much more about this in the section on DBI, once I get around to writing that.
A few months ago, Gurusamy went to work at ActiveState, and there was much rejoicing.
So, grab ActivePerl from ActiveState, and install it.
Open a DOS prompt, and change to the bin subdirectory of wherever you installed Perl. Type "perl ppm.pl". (If you have the perl bin directory in your path, you can just type ppm.) This will launch an interactive shell with a prompt that looks like:
PPM>At the prompt, you can type various commands. For database access, there are several modules that you might want, so we'll install all of them now. Type "install Win32-ODBC", and answer "y" when asked if you want to install it. Similarly, type "install DBI" and "install DBD-ODBC" to install those modules.
Note that this PPM (Perl Package Manager) installs these modules by making a socket connection out to the Internet, to www.activestate.com, to get those install files. If you are on an unconnected machine, or have a restrictive firewall, this could cause some problems.
For more details on installing Perl modules on NT, see Installing Perl Modules on NT.
[ TOC ]