Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » SQL Anywhere Server - Programming » SQL Anywhere Perl DBD::SQLAnywhere API

Introduction to DBD::SQLAnywhere Next Page

Installing DBD::SQLAnywhere on Windows

To prepare your computer
  1. Install ActivePerl 5.6.0 or later. You can use the ActivePerl installer to install Perl and configure your computer. You do not need to recompile Perl.

  2. Install Microsoft Visual C++ or Microsoft Visual Studio .NET and configure your environment.

    If you did not choose to configure your environment at install time, you must set your PATH, LIB, and INCLUDE environment variables correctly before proceeding. Microsoft provides a batch file for this purpose. For example, a batch file called vcvars32.bat is included in the Vc7\bin subdirectory of the Visual Studio .NET 2003 installation. Open a new system command prompt and run this batch file before continuing.

  3. To install the DBI Perl module on Windows
    1. At a command prompt, change to the bin subdirectory of your ActivePerl installation directory.

      The system command prompt is strongly recommended as the following steps may not work from alternative shells.

    2. Start the Perl Module Manager by executing the following command.


      If ppm fails to start, check that Perl is installed correctly.

    3. Enter the following command at the ppm prompt.

      query dbi

      This command should generate two lines of text similar to those shown below. In this case, the information indicates that ActivePerl version 5.8.1 build 807 is running and that DBI version 1.38 is installed.

      Querying target 1 (ActivePerl
        1. DBI [1.38] Database independent interface for Perl

      If DBI is not installed, you must install it. To do so, enter the following command at the ppm prompt.

      install dbi
    4. Exit from the Perl Module Manager by executing the following command.

    To install DBD::SQLAnywhere on Windows
    1. At a system command prompt, change to the src\perl subdirectory of your SQL Anywhere installation.

    2. Enter the following commands to build and test DBD::SQLAnywhere.

      perl Makefile.PL

      If for any reason you need to start over, you can run the command make clean to remove any partially built targets.

    3. To test DBD::SQLAnywhere, copy the sample database file to your src\perl directory and make the tests.

      copy "samples-dir\demo.db" .

      For information about the default location of samples-dir, see Samples directory.

      dbeng10 demo
      nmake test

      If the tests do not run, ensure that the win32 subdirectory of the SQL Anywhere installation is in your path.

    4. To complete the installation, execute the following command at the same prompt.

      nmake install

    The DBD::SQLAnywhere interface is now ready to use.