in reply to Win32::ODBC undefined DSN
BBQ is dead right. DBI is by far the best was to access databases in Perl. The platform independence is so useful.
I recently wrote a program which replicated files between systems using a configuration held in a database. I developed the application using Ingres as the database, but when we went live it was using a Sybase database.
The conversion took 5 minutes and worked first time.
You do get some issues such as connection parameters being different, and there are differences in SQL syntax (e.g. Ingres and Sybase swap the FROM and SET parts of an UPDATE statement). Otherwise it is a good generic interface.
'Programming the Perl DBI' from O'Reilly is a good book to learn all about it and has a section on differences between databases. It even has a chapter on DBI and ODBC interaction talking about both DBD::ODBC in DBI and a comparision to WIN32::ODBC.
Hope this helps.
|