DBD::Ingres -- an Ingres interface for Perl 5 using DBI. Copyright (c) 1996,1997 Henrik Tougaard You may distribute under the terms of either the GNU General Public License or the Artistic License, as specified in the Perl README file. ANNOUNCEMENT: A new version of DBD::Ingres has just been uploaded to CPAN. It will appear in the mirrors during the next couple of days. New features: o Support for placeholders and binding. You can now do: use DBI qw(:sql_types); .... $sth = $dbh->prepare("insert into tab(c1, c2) values(?, ?)"); $sth->bind_param(1, "col 1", SQL_CHAR); $sth->bind_param(2, 2, SQL_INTEGER); $sth->execute; $sth->bind_param(2, 7, SQL_INTEGER); $sth->execute; (with appropriate errorchecks :) and have inserted two rows: 'col 1', 2 'col 1', 7 Binding can be used in most statements. See the SQL Reference Manual for details. o A function for retrieving database events has been added. See Ingres.pm for details. A general event-handling method has not been defined in the DBI (yet). This function is intended as a stopgap and will (possibly) be depreceated when (and if) a DBI-event-spec is available. Use it at your own risk. o The DBD::Ingres modules now use the DBI template files and are are compliant with the DBI specs as of DBI version 0.90. This implies some changes that may break 'old' DBD::Ingres scripts. + $dbh->rows has been removed This affects the Ingperl variable $sql_rowcount, which is no longer strictly read-only. I have done my best to ensure that this change will not break ingperl- scripts. DBD-style scripts will have to check that $dbh->rows is not used - or wait for an error at runtime ;-} + newstyle connect has autocommit on, oldstyle (and ingperl) still has autocommit off. + Some $sth attributes have been renamed: SqlLen -> ing_length SqlType -> ing_type The old names will be available for an undefined period. + $sth->{TYPE} returns DBI-standard values: int: SQL_INTEGER float: SQL_FLOAT money: SQL_DECIMAL char, varchar, text etc: SQL_CHAR/SQL_VARCHAR date: SQL_CHAR + $sth->{ing_type} returns what $sth->{TYPE} used to return, ie: 'i', 'f' and 's'. o Test scripts have been moved to the (normal) t/ directory. BEFORE BUILDING, TESTING AND INSTALLING this you will need to: Build, test and install Perl 5.004 (or newer) It is very important to test it and install it! Build, test and install the DBI module. It is very important to test it and install it! *** DBI must be at least version 0.90 *** BUILDING If Perl5 is installed do: perl Makefile.PL If Perl5 is NOT installed install it, and come back here later! Then do: make make test make install HP-UX users (and others) will have to build perl with static extensions: make perl make test make inst_perl See the MakeMaker docs for further: perldoc ExtUtils::MakeMaker The make test pass will ask for at databasename (if not given in one of the DBI environment variable (see DBI.pm for particulars). It will then create a table named 'testhththt' in this database, manipulate it and delete it again. It is important for the succes of the test that you have the neccesary Ingres permissions. The ingtest.pl script is a "quick" hack of the test for ingperl (the "old" perl4 interface). If it fails horribly, see below. Do NOT hand edit the generated Makefile unless you are completely sure you understand the implications! Always try to make changes via the Makefile.PL command line and/or editing the Makefile.PL. You should never need to make any changes. If you do *please* let me know so that I can try to make it automatic in a later release. KNOWN PROBLEMS: o the arguments to &sql(connect) must be given in the order: database-name username other-options otherwise the check for username wil fail. o VMS build fails. I have built with success on VMS after 'hacking' the descrip.mms file a bit. TO DO LIST: o Add support for OpenIngres 1.2: blobs etc. IF YOU HAVE PROBLEMS: Firstly, check the Frequently Asked Questions, Known Bugs and any other pertinent documents at: http://www.hermetica.com/technologia/DBI If this does *not* resolve your problem, please post details to dbi-user@fugue.com and CC them to me at ht@datani.dk. Please include: 1. A complete log of a complete build, e.g.: perl Makefile.PL -v (do a make realclean first) make make test DBI_TRACE=3 make test 2. Full details of which version of Ingres/esql and Perl you're using. 3. The output of: perl -e 'use Config; print Config::myconfig()' 4. If you get a core dump, try to include a stack trace from it. If the stack trace mentions XS_DynaLoader_dl_load_file then rerun make test after setting the environment variable PERL_DL_DEBUG to 2. Similarly, get the Devel::CoreStack module and use it. 5. Please don't post problems to comp.lang.perl.misc or perl5-porters. 6. If you are not currently subscribed to the mailing list please subscribe via http://www.fugue.com/dbi Regards, Tim, Al & Henrik. Original document: (c)Tim Bunce Amendments: (c)Alligator Descartes Further amendments: (c)Henrik Tougaard