Installation notes for Canaima Software's f90SQL for Compaq (Digital) Visual Fortran ========================================== Product Description =================== f90SQL-Pro is a library of functions and subroutines that works as an interface between your Fortran programs and the Microsoft Windows Open Database Connectivity (ODBC) API. f90SQL offers a convenient and familiar way to read and write data directly from your Fortran programs to many database and spreadsheet formats, including (but not limited to): Excel, Lotus 1-2-3, Microsoft Access, FoxPro, Paradox, Oracle, Sybase, Ingres, Informix, and Microsoft SQL-Server. As long as the application offers an ODBC interface to its data files, f90SQL lets you read and write data to the native application's format directly from your Fortran programs. f90SQL-Lite is a special version of f90SQL-Pro, Canaima Software's Database Connectivity Library for Fortran. While f90SQL-Pro is optimized to handle large record sets with a small memory foot-print, f90SQL-Lite is optimized to work with small record sets, and a limited number of database connections. Upgrading from previous versions ================================ If you are upgrading from a previous version of f90SQL-Pro or f90SQL-Lite, you must remove the older installation before installing this new version. The new version of the library is 100% compatible with older versions, so you do not need to recompile applications that are already running. ODBC Version ============ f90SQL ODBC library for Compaq Visual Fortran needs version 3.5 or higher of the ODBC Driver Manager. If your system has an earlier ODBC version, f90SQL may not work properly. You can download the latest release of the ODBC Driver Manager from Microsoft's web site (http://www.microsoft.com) or from Canaima Software's web site (http://www.canaimasoft.com). You can also install ODBC ver. 3.5 from this CD, by running mdac_typ.exe from directory \drivers. Example programs ================ Several of the example programs use the BookSales database included in the subdirectory Examples\Database. To run these programs you must create a Data Source Name (DSN) using the ODBC Administrator from the Control Panel. There is a section in this readme.txt file with more detailed information on how to create a DSN in your system. Several of the examples have versions that demonstrate features available only in f90SQL-Pro. All the examples that run with f90SQL-Lite have an DVF_MakeLite.bat command file that can be used to compile and link the examples with f90SQL-Lite.If you have installed f90SQL-Pro, you can use DVF_Make.bat or DVF_MakeLite to compile all the examples. Installation issues =================== f90SQL ODBC Library for Compaq Visual Fortran expects to find version 5.0 or higher of Compaq (Digital) Visual Fortran installed in your system. The set up program attempts to detect the installed version of Compaq Visual Fortran by checking the CVF key in your Windows Registry. If Setup cannot detect the presence of Compaq Visual Fortran, it will still allow you to complete the installation of f90SQL. However, you have to manually enter the directories where the libraries and Fortran modules will be stored. If you have Compaq Visual Fortran installed in your system, and for any reason the Setup program cannot detect it, you should indicate the following directories for these f90SQL components: f90SQL Library Component: Included Files: f90SQL.lib Copy to the library directory of your Compaq Visual Fortran installation (usually the directory DevStudio\DF\Lib). f90SQL Module files: Included Files: f90SQL.f90, f90SQL.obj, f90SQL.mod, f90SQLConstants.f90, f90SQLConstants.obj, f90SQLConstants.mod, f90SQLStructures.f90, f90SQLStructures.obj, f90SQLStructures.mod, ReCompilef90SQL.bat Copy to the include directory of your Digital Visual Fortran installation (usually the directory DevStudio\DF\include). If Setup was unable to detect your installation of Compaq Visual Fortran it would indicate so before continuing with the installation of f90SQL. Setting f90SQL environment variables ==================================== f90SQL's Setup creates two environment variables with the paths to f90SQL library and module files. These variables facilitate compilation of programs that use f90SQL, and allow installing f90SQL files in directories other than the default directories of your compiler. For the environment variables to take effect, you must log out from Windows, and log in again. If for any reason Setup cannot set these environment variables, you can do it manually by following the instructions below. Windows NT/2000 1) open the Windows Control Panel 2) Click on the System icon 3) Click on the Environment tab 4) In the Variable box enter f90SQLDVFLibDir 5) In the Value box enter the path to the directory where you installed file f90SQL.lib 6) Click Set 7) In the Variable box enter f90SQLDVFModDir 8) In the Value box enter the path to the directory where you installed f90SQL module files (*.mod) 9) Click Set again 10 Click Apply. Windows 95/98 1) Open the file autoexec.bat located in the root directory of your system hard drive. 2) Add the following two lines to the end of the file: SET f90SQLDVFLibDir= SET f90SQLDVFModDir= where is replaced by the path to the directory where you installed file f90SQL.lib, and is replaced by the path to the directory where you installed f90SQL module files (*.mod). Installing on computers with FAT file systems ============================================= If your hard drive is using FAT, you should install f90SQL components to directories with short (8 or less characters) names. Otherwise the compiler may not be able to resolve the path to f90SQL modules and libraries. f90SQL Technical Support ======================== Canaima Software's web server (http://www.canaimasoft.com) has an on-line discussion group for f90SQL-related topics. This is the best place to post your questions or comments, and get quick and knowledgeable answers from our technical support group. f90SQL-Lite users are supported only on a best-effort basis through this discussion group. f90SQL-Pro users can contact Lahey Computer Systems technical support at support@lahey.com. Files included in this release ============================== The following is a list of the core files included in the f90SQL distribution: File: f90SQL.Lib Description: f90SQL Library Location after installation: the Lib directory of your Digital Visual Fortran. File: f90SQLDVF.DLL Description: f90SQL Dynamic Link Library (DLL) Location after installation: Your Windows System directory. Comments: This is the only redistributable component of the f90SQL ODBC Library for Digital Visual Fortran. Files: f90SQLConstants.f90 f90SQLConstans.mod f90SQLConstans.obj f90SQLStructures.f90 f90SQLStructures.mod f90SQLStructures.obj f90SQL.f90 f90SQL.mod f90SQL.obj Description: f90SQL Modules. Location after installation: the Include directory of your Digital Visual Fortran installation File: ReCompilef90SQL.bat Description: make file to re-compile f90SQL Modules. Location after installation: the Include directory of your Digital Visual Fortran. Files: f90SQLHelp.chm f90SQLHelpTOC.hhc Description: f90SQL User Manual, in Microsoft's HTML-Help format. Location after installation: The directory you selected for the f90SQL documentation. File: hhupd.exe Description: HTML-Help viewer installation program. Comments: Run this program if you cannot open f90SQLHelp.chm. Follow the instructions. This program is copyrighted by Microsoft Corporation, and freely distributable. Make sure you read and agree with Microsoft's EULA conditions. To install the HTML-Help viewer in Windows NT, you need Administrator privileges. File: mdac_typ.exe Description: Redistributable files to install Microsoft's ODBC driver manager ver. 3.5. Comments: Run this program if your ODBC Driver Manager is a version older than v3.5. Follow the instructions. This program is copyrighted by and designated as redistributable by Microsoft Corporation. Make sure you read and agree with Microsoft's EULA conditions. Verifying the version of the ODBC Driver Manager ======================================== f90SQL needs version 3.5 or higher of the ODBC driver manager. Follow the instructions below to verify the version of the ODBC Driver Manager installed in your system: 1) Open your Windows System folder with Microsoft's Windows Explorer. 2) Right-click on file ODBC32.DLL, select Properties from the pop-up window. 3) Click on the tab labeled version. 4) The version of the Driver manager appears next to the label "File Version". If your ODBC Driver Manager version is earlier than 3.5, you should run program mdac_typ.exe to update the driver. You can download the latest version of the ODBC Driver manager from Canaima Software's or Microsoft's web server. Creating a DSN for the BookSales Database ========================================= Many of the examples that come with f90SQL need a Data Source Name entry for the BookSales database. Follow the instructions below to create a Data Source Name (DSN) for the BookSales database in the Examples\Database directory of your f90SQL installation: 1) Open Windows Control Panel 2) Double click the ODBC icon 3) Select the tab labeled System DSN 4) Click the Add button, select Microsoft Access Driver and click Finish 5) This will pop up a window requesting information about the new data source. Enter the following: 5.1) In Data Source Name enter "BookSales" (without the quotes) 5.2) Click the Select button and select file Booksales.mdb in your hard drive. 5.3) Click Ok New in version 1.10.000 ======================= 1) Improved performance. We have fine-tuned several f90SQL subroutines, to improve their performance. 2) Improved installation process. The new set up program is better at detecting Fortran installations for those compilers that do not use the registry to store their set up. The new f90SQL set up also creates environment variables that indicate the location of the f90SQL library and modules. With the new set up program, you can install f90SQL for more than one compiler vendor at the same time, without having to do manual installations. 3) Fixed subroutine f90SQLFunctionExists. The subroutine now works with vectors of any size as arguments. 4) Fixed f90SQLGetFunctions. This subroutine was not working properly with Salford Fortran 95. 5) A new set of functions has been added to the library. These functions return the size (in bytes) of the structures defined in f90SQL. The following is a list of the new functions: function SizeOfDATE_STRUCT() function SizeOfTIME_STRUCT() function SizeOfTIMESTAMP_STRUCT() function SizeOfSQL_NUMERIC_STRUCT() function SizeOfSQLGUID_STRUCT() function SizeOfSQL_DAY_SECOND_STRUCT() function SizeOfSQL_YEAR_MONTH_STRUCT() function SizeOfSQL_INTERVAL_TIME_STRUCT() function SizeOfSQL_INTERVAL_STRUCT() function SizeOff90SQL_INFO_STRUCT() function SizeOff90SQL_TYPE_STRUCT() function SizeOff90SQL_COLUMNS_STRUCT() function SizeOff90SQL_SPEC_COLS_STRUCT() function SizeOff90SQL_STATISTICS_STRUCT() function SizeOff90SQL_TABLES_STRUCT() function SizeOff90SQL_PRIMARYKEYS_STRUCT() function SizeOff90SQL_PROC_COLS_STRUCT() function SizeOff90SQL_COL_PRIV_STRUCT() function SizeOff90SQL_FOREIGNKEYS_STRUCT() function SizeOff90SQL_TABLE_PRIV_STRUCT() All functions are called without arguments. They return an integer(SQLINTEGER_KIND) type. The interface to these functions is located in the module f90SQL.f90. Note that, because of memory alignment issues, the size in bytes of a structure may not be the same as the sum of the bytes used by the structure components. 6) Several minor editorial changes were made in the documentation. 7) Minor changes were made in the example programs to make them compatible with f90SQL-Lite. New in version 1.10.003 ======================= f90SQL version 1.10.003 is a maintenance release that fixed two bugs: 1) The interface module for f90SQLEndTran erroneously declared arguments Handle and CompletionType as intent(out), when they should have been defined as intent(in). This caused a compiler error when programs tried to pass the f90SQL-defined constants for argument CompletionType. 2) Subroutine f90SQLExecDirect was running slow due to a bug that forced queries to execute twice. This bug was introduced with the release of ver. 1.10.001 and did not affect previous f90SQL releases. New in version 2.00.001 ======================= f90SQL version 2.00.001 is a maintenance release. No additional bugs have been reported since version 1.10.003. However, version 2.00.001 fixes some potential compatibility issues with Windows 2000. The main features of f90SQL vers. 2.00.001 are the new f90SQL Wizard and some important changes in the license agreement to make it more developer- friendly. See the file License.txt for more details. Release notes for f90SQL-Lite ============================= IMPORTANT: These notes apply only to f90SQL-Lite users. f90SQL-Lite and f90SQL-Pro share most of their functionality. Because of this, both versions are distributed with the same manual, which describes f90SQL-Pro. f90SQL-Lite, however, has some limitations that are not present in f90SQL-Pro. This section contains a description of these limitations. 1. Functions and subroutines included in f90SQL-Pro but not available in f90SQL-Lite: The following functions and subroutines are not available in f90SQL-Lite (possible workarounds are included in parenthesis) - f90SQLDriverConnect (Use f90SQLConnect instead) - f90SQLBrowseConnect (Use f90SQLConnect instead) - f90SQLGetDescField (None, descriptors rarely need to be used) - f90SQLGetDescRec (None, descriptors rarely need to be used) - f90SQLSetDescField (None, descriptors rarely need to be used) - f90SQLSetDescRec (None, descriptors rarely need to be used) - f90SQLCopyDesc (None, descriptors rarely need to be used) - f90SQLBindParameter (Include parameter values directly in your query string) - f90SQLPrepare (Use f90SQLExecDirect instead) - f90SQLExecute (Use f90SQLExecDirect instead) - f90SQLDescribeParam (None) - f90SQLNumParams (None) - f90SQLParamData (Include parameter values directly in your query string) - f90SQLPutData (None) - f90SQLGetData (None. Do no attempt to read long data with f90SQL-Lite) - f90SQLSetPos (None. f90SQL-Lite only allows forward reading of record sets) - f90SQLBulkOperations (None) - f90SQLLenBinaryAttr (None) - f90SQLLenDataAtExec (None) 2. f90SQL-Lite limitations in the size of record sets: f90SQL-Lite is optimized for small record sets. Because of this, f90SQL-Lite limits the number of rows in a record set to about 128. However, this number is not exact. Attempts to fetch more than 128 rows will return the value SQL_NO_IMPLEMENTED in argument iRet. Attempts to fetch data past the number of rows naturally returned by a query return SQL_NO_DATA in iRet. You can use these two constants to discern when you have reached the natural end of a record set, or if your record set is larger but you have reached the row-limit imposed by f90SQL-Lite. A workaround to the 128-row limitation in f90SQL-Lite is to perform multiple sequential queries, each query targeting a portion of the needed data. You must release and reallocate the statement handle between each query. f90SQL-Pro has been optimized to handle large record sets with a small memory footprint. It does not have any limitations in the number of rows that can be fetched. 3. f90SQL-Lite limitations in the fetch direction of record sets: In f90SQL-Lite, subroutine f90SQLFetchScroll can only be called with SQL_FETCH_NEXT for the fetch orientation argument. Attempts to call f90SQLFetchScroll with an orientation other than SQL_FETCH_NEXT will fail and return SQL_NO_IMPLEMENTED in iRet. f90SQL-Pro allows all the other options for f90SQLFetchScroll (i.e. SQL_FETCH_PRIOR, SQL_FETCH_FIRST, SQL_FETCH_LAST, SQL_FETCH_ABSOLUTE, SQL_FETCH_RELATIVE and SQL_FETCH_BOOKMARK). 4. f90SQL-Lite limitations on statement attributes: f90SQLSetStmtAttr does not accept the following attribute arguments (you cannot change their values): SQL_ATTR_APP_PARAM_DESC, SQL_ATTR_ASYNC_ENABLE, SQL_ATTR_CURSOR_SCROLLABLE, SQL_ATTR_PARAM_BIND_OFFSET_PTR, SQL_ATTR_PARAM_BIND_TYPE, SQL_ATTR_PARAM_OPERATION_PTR, SQL_ATTR_PARAM_STATUS_PTR, SQL_ATTR_PARAMS_PROCESSED_PTR, SQL_ATTR_PARAMSET_SIZE, and SQL_ATTR_ROW_OPERATION_PTR. Attempts to set any of these attributes will return SQL_NO_IMPLEMENTED in iRet. You can, however, review the value of any of these attributes using f90SQLGetStmtAttr. f90SQL-Pro does not have any of these limitations. 5. f90SQL-Lite limitations in the number of concurrent handles and connections: f90SQL-Lite is optimized to work with just one database connection. Because of this f90SQL-Lite only allows one environment handle, one connection handle and one statement handle to be functional at any given time. Attempts to allocate more handles will return SQL_NO_IMPLEMENTED in argument iRet. f90SQL-Lite only allows you to open a single connection to a data source at any given time, although you may open more than one connection in a single program. f90SQL-Pro is optimized to handle many open database connections at the same time. It does not have any limitations in the number of connections you can open. 6. f90SQL-Lite limitation in the number of calls to f90SQLExecDirect: f90SQL-Lite limits to 100 the number of calls made to f90SQLExecDirect using the same statement handle. The counter is reset each time you deallocate the statement handle, so your programs can make more than 100 calls to f90SQLExecDirect provided you deallocate/reallocate the statement handle every 100 calls. f90SQL-Pro does not have any of these limitations. 7. Some example programs do not compile with f90SQL-Lite: Several of the example programs included in the f90SQL distribution are demonstrations of features available only in f90SQL-Pro. If you attempt to compile these examples using f90SQL-Lite you will get error messages indicating that some external subroutines could not be found. For some of these cases, we have provided workarounds that can be compiled using DVF_MakeLite.bat The following examples will not compile with f90SQL-Lite: Example51: Demonstrates the use of concurrent connections. f90SQL-Lite is not capable of this. Example54: Demonstrates the use of parameterized queries and prepared statements. f90SQL-Lite does not support these two options. Example57: Works only partially because f90SQL- lite can fetch only in the forward direction. Example58: Demonstrates the use of queries with parameters, but f90SQL-Lite does not support parameterized queries. Example59: Demonstrates how to update records using f90SQLSetPos. f90SQL-Lite does not support this instruction. Example61: Demonstrates the use of PutData to update long binary fields. f90SQL-Lite does not support this instruction. Example62: Demonstrates column-wise binding of parameters. f90SQL-Lite does not support this option. The following examples have been provided with workarounds that will compile with f90SQL-Lite: Example52, Example53, ExcelRead and ExcelWrite. All other examples work fine with f90SQL-Lite. Upgrading to f90SQL-Pro ======================= If you are a user of f90SQL-Lite and want to upgrade to f90SQL-Pro, check Lahey Computer System's web page for prices, availability, and international resellers in your country. Contacting Lahey Computer Systems, Inc. ======================================= 865 Tahoe Blvd. P.O. Box 6091 Incline Village, NV 89450 800-548-4778 775-831-2500 775-831-8123 Fax http://www.lahey.com Contacting Canaima Software, Inc. ================================= P.O. Box 13162 La Jolla, CA. 92039 - USA Tel/Fax: (619) 233-6831 http://www.canaimasoft.com e-mail: support@canaimasoft.com Copyrights and trademarks: ========================== f90SQL and its logo are trademarks of Canaima Software, Inc. f90SQL, f90SQL-Lite and f90SQL-Pro are Copyright 1998-2000, Canaima Software, Inc. Absoft and Absoft Pro Fortran are trademarks of Absoft Corporation. Windows, Windows 95 and Windows NT, ODBC, Microsoft Access, Excel and Microsoft SQL-Server are trademarks of Microsoft Corporation. Digital Visual Fortran is a trademark of Digital Equipment Corporation. Compaq Visual Fortran is a trademark of Compaq Computer Corporation. Oracle is a trademark of Oracle Corporation. Lahey, Lahey Fortran 95, LF95, Lahey Fortran 90, and LF90 are trademarks of Lahey Computer Systems Corporation. Salford, Salford Fortran 95, and FTN95 are trademarks for Salford Software, LTD. All other brands and names are the trademarks of their respective holders.