DBD::Adabas -- DBD module interfacing the Adabas D database.

This module is based on DBD::ODBC:

   $Id: README,v 1.1 1998/04/22 17:42:33 joe Exp $
   Copyright (c) 1994,1995,1996,1997  Tim Bunce
   portions Copyright (c) 1997 Jeff Urlwin
   portions Copyright (c) 1997 Thomas K. Wenrich
   portions Copyright (c) 1998 Jochen Wiedmann

   You may distribute under the terms of either the GNU General Public
   License or the Artistic License, as specified in the Perl README file.



WARNING:
========
THIS IS MOSTLY ALPHA SOFTWARE. Your mileage may vary.

Most of the code (and most parts of this README) were stolen from the 
DBD-Solid distribution.  I suspect most problems you may encounter with
this release are related to my efforts to port it to straight ODBC.


REQUIREMENTS:
=============
*BEFORE* BUILDING, TESTING AND INSTALLING this you will need to:

    Build, test and install Perl 5 (at least 5.004).
    It is very important to TEST it and INSTALL it!

    Build, test and install the DBI module (at least DBI 0.86).
    It is very important to TEST it and INSTALL it!

    Remember to *read* the DBI README file!


BUILDING:
=========

1.) Create a file /usr/spool/sql/config/odbc.ini with the following
    contents:

	[ODBC Data Sources]
	test

	[test]
	ServerDB=test
	ServerNode=

    Of course you have to replace the database name "test" with your
    database name.

2.) Setup these environment variables:

        DBROOT=/opt/adabas	or whereever you have installed the
				Adabas engine (the directories incl
				and lib are located in $DBROOT)
	DBI_DSN=DBI:Adabas:test	replace "test" with your databases
				name, see above
	DBI_USER=joe		A valid database user
	DBI_PASS=pwd		joe's password

	export DBROOT DBI_DSN DBI_USER DBI_PASS

3.) Build the module:

	perl Makefile.PL
	make

    If you want to create a static perl for debugging purposes, do the
    following:

	SHOW_ODBC_PROBLEMS=1
	export SHOW_ODBC_PROBLEMS
	perl Makefile.PL OPTIMIZE=-g
	make
	make perl

    The last command will fail in the linker stage. To finish, just
    repeat the last $(CC) or $(LD) command and add the following
    flags:

	cc ... -L/opt/adabas/lib /opt/adabas/lib/odbclib.a -lsqlrte -lsqlptc

    Don't ask me why SAG is using a brain damaged library name like
    odbclib.a ...

TESTING

    make test
  
    You'll note that two test scripts will fail. As far as I know these
    are bugs in the ODBC driver, in particular:

	- NUL bytes aren't treated appropriately when using

		$sth = $dbh->prepare("INSERT INTO $table VALUES (?, ?)");
		$sth->bind_param(1, $id, { TYPE = &DBI::SQL_INTEGER });
		$sth->bind_param(2, $blob, { TYPE = &DBI::SQL_VARBINARY });
		$sth->execute();

	  This makes test 11 in t/40blobs.t failing.

	- Field attributes seem to be incorrect; when creating a table
	  with

		CREATE TABLE $table (id integer NOT NULL,
				     name CHAR(64),
				     PRIMARY KEY(id))

	  the both fields are reported as Nullable by the ODBC driver.
	  This breaks test 8 in t/40listfields.t.


IF YOU HAVE PROBLEMS:

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 not 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.

This software is supported via the dbi-users mailing list.  For more
information and to keep informed about progress you can join the a
mailing list via http://www.fugue.com/dbi (if you are unable to use the
web you can subscribe by sending a message to dbi-request@fugue.com, it
may take a few days to be processed).

Please post details of any problems (or changes you needed to make) to
dbi-users@fugue.com and CC them to joe@ispsoft.de and
jurlwin@access.digex.net. But note...

** IT IS IMPORTANT TO INCLUDE THE FOLLOWING INFORMATION:

1. A complete log of a all steps of the build, e.g.:

  perl Makefile.PL           (do a make realclean first)
  make
  make test
  make test TEST_VERBOSE=1   (if any tests fail)

2. Full details of which software you are using, including:

  Perl version (the output of perl -V)

It is important to check that you are using the latest version before
posting. If you're not then I'm *very* likely to simply say "upgrade to
the latest". You would do yourself a favour by upgrading beforehand.

Please remember that I'm _very_ busy. Try to help yourself first,
then try to help me help you by following these guidelines carefully.

Regards,
Tim, Jeff and Jochen

===============================================================================
Examples and other info:

DBI 'home page': http://www.hermetica.com/technologia/DBI
Jeff's 'home page' : http://www.access.digex.net/~jurlwin

