═══ 1. Updating from version 2.1A ═══ If you are updating to version 2.1B from 2.1A, you should be aware of the following changes to VX-REXX: o If you are using DB2/2 you must rebind your databases. The bind files have changed in VX-REXX version 2.1B. You must rebind VX-REXX to your databases. Use the BINDDBI command to do this. In version 2.1, the database controls came with a number of bind (.BND) files. In version 2.1A, they were replaced with a single bind file called WDB221A.BND. In version 2.1B, the bind file is called WDB221B.BND. ═══ 2. Commonly Asked Questions ═══ Database topics: o How to I install the sample database on... - a remote DB2/2 server? - a remote Watcom SQL server? - a remote DB2 server? - a remote AS/400 server? o How to I create a new database on... - a remote DB2/2 server? - a remote remote Watcom SQL server? - a remote DB2 server? - a remote AS/400 server? o How do I bind to DB2/2 databases? o How do I bind to a remote host using DDCS/2? o How do I specify the qualifier for the system tables when using DB2? o Why can't I connect to a remote DB2/2 database? o Why can't I connect to a DB2/2 database using ODBC? o Why can't I list tables in a remote DB2/2 database? o How do I control how rows are locked when using DB2/2? o What is a "Timestamp conflict"? o How can I suppress the startup message from Watcom SQL? o What does "Unable to initialize DBI" mean? o What does "SQL0204N 'USERID.xxxx' is an undefined name" mean? Charting topics: o How do I create XY charts? ═══ Creating remote databases with DB2/2 ═══ Remote databases must be created on the database server machine. You cannot create new databases from a client workstation. To create a new database on a DB2/2 server, follow these steps: 1. Install the DB2/2 server software on the server machine. (If the software has already been installed, you can omit this step.) 2. Start the DB2/2 Directory Tool program. 3. Select System Database from the Directory menu. A list of existing databases will be shown. 4. Select Create from the Database menu. A prompt for the database name and drive letter will appear. 5. Fill in the database name and drive letter, then press Create. Once the database has been created, you have to catalog the new database on the client computers, and bind VX-REXX to the database. See also: o Binding databases o Binding databases through DDCS/2 ═══ Creating remote databases with DB2 ═══ Remote databases must be created on the database server machine. You cannot create new databases from a client workstation. To create a new database on a DB2 server, follow these steps: 1. Create a new database on the DB2 server. Follow the instructions that came with the sever software to do this. 2. On the client workstation, catalog the new database. 3. On the client workstation, bind VX-REXX to the database using the BINDDBI utility. See also: o Binding databases o Binding databases through DDCS/2 o Specifying the system table qualifier with DB2 ═══ Creating remote databases with Watcom SQL ═══ Remote databases must be created on the database server machine. You cannot create new databases from a client workstation. To create a new database on a Watcom SQL server, follow these steps: 1. Install the Watcom SQL server software on the server machine. (If the software has already been installed, you can omit this step.) 2. Create a new database using the DBINIT command. From an OS/2 command line type dbinit database where database is the name of the database you want to create. 3. To start the database server, type dbserver database at an OS/2 command line prompt. If the Watcom SQL client software is correctly installed, you should be able to access the database. ═══ Creating remote databases on an AS/400 ═══ Remote databases must be created on the remote host machine. You cannot create new databases from a client workstation. To create a new database on an AS/400, follow these steps: 1. Install the database software on the AS/400. (If the software has already been installed, you can omit this step.) 2. Before you create a remote database, a collection must be created on the AS/400 with the same name as the userid that will be used when creating the database. You can do this with a command like: CREATE COLLECTION USERID 3. Create the new database by following the instructions supplied with your AS/400 database software. 4. On the AS/400, create a Watcom library. This can be done with a command like: CRTLIB LIB(WATCOM) TYPE(*PROD) TEXT('WATCOM SQL Packages Library') AUT(*USE) 5. Catalog the new database on the client workstation. Refer to the DB2/2 Guide for more information about cataloging. 6. Bind VX-REXX to the new database. You can do this with the BINDDBI program that comes with VX-REXX. Type the following from an OS/2 command line: BINDDBI -dWSAMPLE -fUSA -kALL See Using BINDDBI. for more information on command line options for BINDDBI. See also: o Binding databases through DDCS/2 o Specifying the system table qualifier with DB2 ═══ Installing the sample database on a DB2/2 remote server ═══ All of the sample programs in the VX-REXX Database Samples folder assume you have installed the VX-REXX sample database. To install the sample database, follow these steps: 1. On the server machine, use the DB2/2 Directory Tool to create a new (empty) database. Name the database WSAMPLE. 2. On the client workstation, catalog the new remote database. (See Connecting to a remote DB2/2 database for details.) 3. On the client workstation, start the VX-REXX Sample Database Generator program. (The icon for this program is in the Database Samples folder, which is in the Watcom VX-REXX folder.) 4. Set the Database field to IBM DB2/2 (network). 5. Press Install and follow any other instructions the program gives you. ═══ Installing the sample database on a remote DB2 server ═══ All of the sample programs in the VX-REXX Database Samples folder assume you have installed the VX-REXX sample database. To install the sample database, follow these steps: 1. On the server machine, create a new (empty) database. Name the database WSAMPLE. 2. On the client workstation, catalog the new remote database. (See Connecting to a remote DB2/2 database for details.) 3. On the client workstation, start the VX-REXX Sample Database Generator program. (The icon for this program is in the Database Samples folder, which is in the Watcom VX-REXX folder.) 4. Set the Database field to IBM DB2/2 (network). 5. Press Install and follow any other instructions the program gives you. ═══ Installing the sample database on a Watcom SQL remote server ═══ All of the sample programs in the VX-REXX Database Samples folder assume you have installed the VX-REXX sample database. To install the sample database, follow these steps: 1. On the server machine, use Watcom SQL's DBINIT program to create a new (empty) database called WSAMPLE. The following command line will do this: DBINIT WSAMPLE 2. Start the database server. Type DBSERVER WSAMPLE 3. On the client computer, start the VX-REXX Sample Database Generator program. (The icon for this program is in the Database Samples folder, which is in the Watcom VX-REXX folder.) 4. Set the Database field to Watcom SQL (network). 5. Press Install and follow any other instructions the program gives you. ═══ Installing the sample database on an AS/400 ═══ All of the sample programs in the VX-REXX Database Samples folder assume you have installed the VX-REXX sample database. To install the sample database, follow these steps: 1. Create a collection on the AS/400 with the same name as the userid that will be used when creating the database. You can do this with a command like: CREATE COLLECTION USERID 2. Create the new (empty) database by following the instructions supplied with your AS/400 database software. 3. On the AS/400, create a Watcom library. You can do this with a command like: CRTLIB LIB(WATCOM) TYPE(*PROD) TEXT('WATCOM SQL Packages Library') AUT(*USE) 4. Catalog the new database on the client workstation. Refer to the DB2/2 Guide for more information about cataloging. 5. On the client workstation, start the VX-REXX Sample Database Generator program. (The icon for this program is in the Database Samples folder, which is in the Watcom VX-REXX folder.) 6. Set the Database field to IBM DB2/2 (network). 7. Press Install and follow any other instructions the program gives you. Note: Some versions of DB/400 do not support foreign keys. The Sample Database Generator attempts to add foreign key information to the database. If the program cannot set up the foreign keys, it will alert you of this error. Press the Ignore button to ignore the error. ═══ Accessing tables in a remote DB2/2 database ═══ You must bind VX-REXX to each database you want to use before you access it. VX-REXX includes the BINDDBI program to do this. For example, to bind the database called WSAMPLE to VX-REXX, type BINDDBI -dWSAMPLE If the database appears empty from the client workstation, it could be because VX-REXX has not been bound to the database. Note: If you are binding to a database on a host database via DDCS/2, you must specify the -f and -k parameters to BINDDBI. For details on these parameters, see Using BINDDBI in the Database Objects Guide. ═══ Binding to a remote host through DDCS/2 ═══ To bind to a remote host through DDCS/2 you must first bind the local DB2/2 utilities to the remote host database management system. To do this, you must run the DDCS/2 utility SQLJBIND. For example, to bind to a database called FILMS when DB2/2 is installed in the SQLLIB directory on drive C, you would type: SQLJBIND FILMS C SQLLIB For more information, please refer to the DDCS/2 Guide. After running SQLJBIND, use the BINDDBI utility to bind to your database. Note: The -f and -k parameters are required with BINDDBI when binding to a database which is accessed using DDCS/2. For example, to bind to the database called FILMS with United States date and time format, with full blocking and fetch-only cursors type: BINDDBI -dFILMS -fUSA -kALL The above commands grant execute permissions to all users. Specifying the -u parameter with a user id or group id will grant permissions only to that user or group. ═══ Specifying the system table qualifier with DB2 ═══ Various implementations of DB2 use different system table qualifiers. You can have the database objects use a particular system table qualifier by specifying "system=..." in the ConnectionParms property of the Connection object. For example, to use a database with system tables which are qualified by SYSTEM, you would specify system=SYSTEM; in the ConnectionParms property of the Connection object. This also allows VX-REXX programs to read system views that have a unique qualifier created by the database administrator if access is restricted to the real system tables. The default system table qualifier is SYSIBM, which is used with DB2/2. ═══ Connecting to a remote DB2/2 database ═══ If your remote database does not appear in the list of databases, or you cannot connect to it, check the following: o Have you installed the client DB2/2 software on your workstation? You must install one of the following configurations on your workstation in order to access remote databases: client, client with local databases, or server. You do no have to install the server on your workstation unless you want other people to have access to your local databases. o Have you cataloged the database on the workstation? To use a remote DB2/2 database, you must tell the DB2/2 client software about the remote database. To do this, you catalog the database on the workstation. For example, suppose you have created a remote database called REMOTEDB on a machine called DBSERVER. To catalog this database, you would take the following steps on the client workstation: 1. Start the DB2/2 Directory Tool program. 2. Open the list of databases by choosing System Database from the Directory menu. 3. Select Catalog from the Database menu to add a new database to the catalog. The program will prompt you for information about the remote database. 4. Type REMOTEDB in the Alias and Database fields. Set the Workstation field to DBSERVER. 5. Press Catalog to add the remote database to the workstation's catalog. o Can you access the database using the DB2/2 Query Manager utility? DB2/2's Query Manger lets you view local and remote DB2/2 databases. If you cannot connect to a remote DB2/2 database using the VX-REXX database objects, try viewing the database using the Query Manger. If the Query Manager does not work either, one of the following is likely to be the cause: - The network transport services (NETBIOS or APPC) are not configured correctly. - The DB2/2 server software is not running on the remote machine. - The DB2/2 client software is not installed on the local computer. ═══ Connecting to a DB2/2 database using ODBC ═══ If you cannot connect to a DB2/2 database using ODBC, and have specified the correct userid and password in the connection object, make sure that the userid and password are in upper case. When using ODBC, the userid and password are case sensitive but DB2/2 requires them to be in upper case. ═══ Controlling how rows are locked when using DB2/2 ═══ How rows in a given DB2/2 database are locked by VX-REXX applictions is set when VX-REXX is bound to the database by using the -iIsolation and -kBlocking parameters with BINDDBI. To lock all rows in the current table, set the Isolation parameter to RR. To stop row locking, in most cases, set the Isolation parameter to UR and set the Blocking parameter to ALL. For example, to use minimal record locking on the database called FILMS, bind with the command: BIND -dFILMS -kALL -iUR By default, the currently fetched row will be locked. This means that other applications accessing the same database table will not be able to update or delete the row currently fetched by the VX-REXX application. The lock on the row is released when a new row is fetched or when the query is closed. Note: Because of the caching system used by VX-REXX when accessing the database, the current row of a query object may not be the currently fetched row, which is managed by DB2/2 itself. For example, if the query object is requested to move to a row which is already in the cache, the currently fetched row (according to DB2/2) will not be changed because a fetch on the database itself will not be performed. To ensure that the query object's current row is the currently fetched row according to DB2/2, the query object's CacheSize property may be set to 1. However, this may result in decreased performance on tables with more than 1000 rows. Note: If a VX-REXX DB2/2 application attempts to update or delete a row which is locked, the application will appear to freeze until the lock is released. This is because DB2/2 holds the request for update or delete until the lock is released. ═══ Timestamp conflicts ═══ If you get an error message that mentions a "timestamp conflict", the most likely cause is that your VX-REXX database DLLs are different that those that were originally bound to the database. Try binding VX-REXX to the database again. If the error persists, contact Watcom technical support. ═══ Suppressing Watcom SQL's startup message ═══ The VX-REXX connection object automatically starts the Watcom SQL engine when the Connect method is invoked if the engine is not already running. When started this way, all messages from the engine come out in the VX-REXX console window. If you want to suppress Watcom SQL's startup message, set the SQLSTART environment variable in your CONFIG.SYS file. If you are using the standalone version of the Watcom SQL, set SQLSTART to DBSTART -q %d If you have the SQL client software installed instead, set SQLSTART to DBCLIENT -q %d ═══ "Unable to initialize DBI" error ═══ If you get the error "Unable to initialize DBI", the VX-REXX controls were not able to load all of their DLLs. Check the following: o Make sure the VX-REXX directory is listed in the LIBPATH in your CONFIG.SYS file. o If you are using DB2/2, make sure the MUGLIB and SQLLIB directories are in your LIBPATH. o If you are accessing your database using ODBC drivers, make sure the directory that contains the ODBC drivers is in your LIBPATH. ═══ SQL0204N Error ═══ DB2/2 returns a SQL0204N error when it can't find a named object (a table, view, column, or index). The most common reasons for getting this message are: o A quoted name uses a different case. DB2/2 respects case in quoted object names. This means that if you create a column with an upper case name (which is the default), and the column name is quoted in a SELECT statment, the name should be in upper case. If the column was created with a lower case name, the name should appear in lower case. If an object name is not in quotation marks, DB2/2 will automatically convert it to upper case. o The object name is misspelled. o The object is not defined in the database. ═══ Creating XY charts ═══ The Charting Package in VX-REXX supports a number of chart types, including XY charts. XY charts are different from other chart types in that the data that is charted is a set of points. All chart types, including XY charts, view the data as a rectangular grid of values. Think of the chart data as a spreadsheet of values with row and column names. Each chart type interprets the rectangular grid of values differently. Bar charts plot each value as a bar, while pie charts plot each value in one column as a slice. The chart data can only be set with the SetDataValue method for chart objects. It takes a row index, a column index, and a data value. This uniquely identifies one value in the rectangular grid of chart data. XY charts plot points. A point is formed by two values: an X co-ordinate and a Y co-ordinate. Since all charts must take their data from the rectangular grid, XY charts form their data by selecting two columns, one representing X values and the other representing Y values. Hence, each row contains two values which form an XY point. For example, suppose you have the following points you want to plot in an XY chart: (2,3), (0,1), (-1,4), (5,2) The following REXX code would set this chart data: call SetDataValue 1, 1, 2 call SetDataValue 1, 2, 3 call SetDataValue 2, 1, 0 call SetDataValue 2, 2, 1 call SetDataValue 3, 1, -1 call SetDataValue 3, 2, 4 call SetDataValue 4, 1, 5 call SetDataValue 4, 2, 2 This is the rectangular grid of values: Column 1 (Xs) Column 2 (Ys) ============= ============= 2 3 0 1 -1 4 5 2 A common mistake is to think that a point like (3,4) is set by calling SetDataValue as follows: SetDataValue( 3, 4, ...) Setting the point (3,4) requires two calls to SetDataValue. In addition, XY charts allow you to display more than one group of points. You may want to have two sets of points, displayed with two different marker styles. By default, the charting package assumes that if you have 'n' columns of data, then you have 'n-1' groups of points, formed by pairing columns 1 and 2, 1 and 3, 1 and 4, etc. Hence, the first column is assumed to contain the common X values, while the remainder are assumed to contain the Y values for each group. If you are only plotting one group of points, then the default method is most likely correct. But if you are plotting many groups of points, then the default may not be appropriate. You can control which columns form the X and Y pairs in the Group Options page in the Chart Editor. The fields labelled 'X Group' and 'Y Group' let you select which columns are used for each set of points in your XY chart. ═══ 3. Restrictions ═══ Known restrictions/problems: Chart object Database objects ═══ Chart object ═══ o Problems have been reported with printing charts to Canon Bubble Jet, Epson LQ 510, and IBM 24e printers. These problems are under investigation. o Printing charts to the Apple LaserWriter NTX II may result in very large PostScript output which can take a long time to print. This is due to the fact that OS/2 may include redundant font definitions in the output. To work around this problem, install the LaserWriter drivers instead. ═══ Database objects ═══ o When connecting to a DB/2 or DB2/2 database, you can have at most 32 open queries. Your project can contain more than 32 queries, but at most 32 can be open at once. This limitation does not apply if you are connected to a Watcom SQL or ODBC database. o The following connection object methods do not work when using some older AS/400 or MVS databases: ListTables, ListColumns, ListForeignKeys, and ListIndexes. o Database table and column names do not appear in the SQL Editor for some versions of the AS/400 database software. The tables cannot be listed because the standard DB2 system tables are not supported by the AS/400 database system. You can work around this problem developing an application against a DB2/2 database and then deploying it on the AS/400. ═══ 4. Errata ═══ Database Objects Guide (July 1994 printing) Omissions Corrections and Additions Chart Object Guide (July 1994 printing) Corrections and Additions ═══ Omissions from the printed manual ═══ The following functions and methods are described only in the online version of the Reference: o Connected (connection object) ═══ Corrections and Additions ═══ The following table lists some corrections and additions to the July 1994 printing of Database Objects Guide. The number in the left column is the page number, and the right column describes the necessary change. 12 In step 3 on this page, the last sentence of the paragraph which begins "If you are using Watcom SQL..." should be "Set the Userid to dba and the Password to sql." 27 The "Closing a query" section should start as follows: "The Close method closes an open query and clears the values of any objects and variables bound to the query. The Close method can optionally commit or rollback changes that have been made to the database. This is equivalent to calling the Connection object methods Commit and Rollback. The Commit method ends..." 28 The following paragraph should be inserted at the end of the "Inserting, updating, and deleting rows" section: When updating and deleting database rows, the Query object uses the most recently fetched values of the bound objects to generate a WHERE clause that identifies the row being modified. This means that ALL rows with columns matching the currently bound ones will be affected. For this reason, it is recommended that the primary key of the table be selected in the SQL statement specified in the SQLStatement property and that corresponding bound objects be created. This will ensure that the Update and Delete methods only act on a single database row by including the primary key in the row identification. If you do not wish to view values in the primary key, the objects bound to those columns may be made invisible by setting the Visible property to 0. The section "Committing and rolling back changes" applies to connection objects, not query objects. This section should have been printed at the bottom of page 24. 31 Picture boxes should be added to the list of objects that you can bind. 67-69 The screen snapshots of the database administrator show the settings notebook having "Foreign Key" and "Index" pages. These pages are not included in the settings notebook. 70 Add the following paragraph to the end of the the "Connect/Disconnect routines" section: "The connect_Fini routine checks for changes to the database before disconnecting. If changes have been made, the routine displays a dialog which asks users if they want to keep the changes or throw them away. If they decide to keep them, the changes are committed to the database before disconnecting. Otherwise changes are thrown away." Delete the last paragraph on the page that begins "The query_Fini routine checks..." 80 The second paragraph in the "Creating a database" section should read: "If you are using DB2/2, the database administrator will use the current userid and password if you are already logged on. If you are not logged on, it will use USERID and PASSWORD for the userid and password. If you are using Watcom SQL, DBA and SQL are always used for the userid and password." 97 In VX-REXX version 2.1A, the four bind files (BINDDBI.BND, DB22CONN.BND, DB22DB.BND, and DB22EXEC.BND) have been combined into a single bind file called WDB2xxx.BND where xxx is the VX-REXX version number (21B for version 2.1 patch level B). You are now licensed to distribute the WDB2xxx.BND file with your applications. See the updated online version of the Database Objects Guide for the revised text of this section. 105 Add the following to the "Notes" section: "The value of the variable is cleared when the query is closed." 111 The "Notes" should read: "The Close method also clears any objects and variables bound to the Query object." 112 In the "Returns" section, the last sentence should read "If the method fails, it returns 0 and the Status connection property contains a printable error." In the "Applies to" section, replace "Query" with "Connection". In the "Examples" section, the REXX code should read: ok = VRMethod( "CNCT_Sample", "Commit" ) 114 Add Commit and Rollback to the list of Connection object methods. 116 In VX-REXX version 2.1B, a new "system=..." connection parameter has been added for use with DB2/2. See the "Notes" section in the updated online version of the Database Objects Guide for details. 118 The syntax for the DBDelete method has been augmented so you can pass a stem variable instead of a single record handle. The "Syntax" section should read: ok = VRMethod( object, "DBDelete", record ) or ok = VRMethod( object, "DBDelete", "reclist." ) Add the following to the "Arguments" section: "reclist." An array of record handles. reclist.0 is the number of handles. reclist.1 is the first handle, reclist.2 is the second handle, and so on. 123 The syntax for the DBUpdate method has been augmented so you can pass a stem variable instead of a single record handle. The "Syntax" section should read: ok = VRMethod( object, "DBUpdate", record ) or ok = VRMethod( object, "DBUpdate", "reclist." ) Add the following to the "Arguments" section: "reclist." An array of record handles. reclist.0 is the number of handles. reclist.1 is the first handle, reclist.2 is the second handle, and so on. 125 The "Notes" section for the Delete method has been updated to include more accurate information on the use of primary keys and deleting multiple database rows. See the updated online Database Objects Guide for details. 126 The "Arguments" section of the DescribeColumns method under col.i.!type should read: is the database type of the column, one of the following: DATE, TIME, TIMESTAMP, SMALLINT, INTEGER, FLOAT, DOUBLE, DECIMAL, STRING, CHAR, VARCHAR, or BINARY. 126 The following paragraph should be inserted at the end of the "Notes" section for the DescribeColumns method: To simplify database interaction, no distinction is made between LONG VARCHAR and VARCHAR column types. Thus, LONG VARCHAR columns are returned as type VARCHAR. 144 Add the following paragraph to the end of the "Notes" section for the Query method: "When accessing DB/2 or DB2/2 databases, a maximum of 32 open queries are allowed per project. Your project can contain more than 32 query objects, but at most 32 can be open at once." 146 The first paragraph at the top of the page should read: "If this property is null and the database requires a password, and the Prompt property is Always or If Needed, the connection object will prompt the user for a password when the Connect method is invoked." 147 Remove the Commit and Rollback from the list of Query object methods. 151 In the description of the Rollback method, a paragraph was added explaining that for DB2/2, Rollback closes the queries that use the connection. For Watcom SQL, the queries stay open. 152 In the "Returns" section, the last sentence should read "If the method fails, it returns 0 and the connection Status property contains a printable error." In the "Applies to" section, replace "Query" with "Connection". In the "Examples" section, the REXX code should read: ok = VRMethod( "CNCT_Sample", "Rollback" ) 153 The following paragraph should be added to the "Notes" section for the RowData method: Columns which contain NULL data are returned as uninitialized members in the stem. For example, if the first column contained NULL data, data.1 would be uninitialized (set to DATA.1) on return. 158 The "Notes" section for the Update method has been updated to include more accurate information on the use of primary keys and deleting multiple database rows. See the updated online Database Objects Guide for details. 163 The command line syntax for BINDDBI now includes parameters to control record locking, the isolation level, and the time/date format. See the updated online Database Objects Guide for details. 165 The Assignment table should be called Assign. The date due column in the Assign table should be called datedue (without a space). The time column in the Class table is actually called times. The Customer, Product, Orders, and OrderItem tables were left out of the E-R diagram. They are included in the online version. ═══ Corrections and Additions ═══ The following table lists some corrections and additions to the July 1994 printing of Chart Object Guide. The number in the left column is the page number, and the right column describes the necessary change. 158 All references in the book to "LegendPosition" should be changed to "LegendType". 161 All references in the book to "LegendType" should be changed to "LegendControl". ═══ 5. New since 2.1 ═══ ═══ 5.1. New in version 2.1b ═══ What's new in version 2.1b: Design environment Chart Editor Query Editor Runtime environment General Connection object Query object Bound Objects General Database administrator ═══ General ═══ o ═══ Chart Editor ═══ o XY, Bubble, and Stock charts no longer affect the legend option when there is no data in the chart. o Documentation and drag and drop macros have been updated for the LegendType and LegendPosition options. LegendType has been changed to LegendControl and LegendPosition has been changed to LegendType. ═══ Query Editor ═══ o The query editor now handles column names with underscores correctly. Previously, the SQL editor would put the closing quotation mark immediately before the underscore rather than at the end of the column name. o The "Changes have been made..." dialog that appears when changes are made to the SQL statement on the test window is now modal to the test window. Previously, clicking on any other query editor window would cause the prompt to be obscured. ═══ General ═══ o ODBC support Previously, some users could not connect to their database when using the ODBC support. ODBC support is now fully functional. ═══ Bound objects ═══ The following changes have been made to bound objects: o List type bound objects The ComboBox, ListBox, Container, and Spin bound objects now ignore the Clear and Reset methods invoked from the query. This is the documented behavior. o ComboBox Bound ComboBoxes no longer flash and scroll when the query is closed while a record is selected. o Container Bound Containers in icon view no longer flash and now empty much more quickly when the query is closed. Additionally, records are now initially visible when the query is opened before the container is made visible. Bound Containers now support queries with duplicate column names. Previously, duplicate columns would not appear in the container. Column names are now reported correctly in bound containers when using DB2 to connect to an MVS host database. Previously, using a bound container with a query on an MVS host database would cause unpredictable results. ═══ Connection object ═══ The following changes have been made to the connection object: o Disconnect method with ODBC When using ODBC, the "Invalid transaction state" error message no longer appears after invoking the disconnect method. o ConnectionParms property Previously, a semicolon was required to terminate the connection parameters string (as well as separate different parameters). Now the terminating semicolon is no longer required. When using DB2/2, you can now specify "system=..." in the ConnectionParms property to indicate the qualifier to be used when accessing the system tables. ═══ Query object ═══ The following changes have been made to the query object: o BindVar method Previously, the BindVar method would cause unpredictable behavior when passed a column name which was not part of the query. Now BindVar returns 0 in this case. o DescribeColumns method The DescribeColumns method now returns the correct column type for each column. Previously, the returned column type was always STRING. Column names are now reported correctly by the DescribeColumns method when using DB2 to connect to an MVS host database. Previously, using the DescribeColumns method with a query on an MVS host database would cause unpredictable results. o Update, Insert, and Delete methods The Update, Insert, and Delete methods now work with queries that select string columns of length greater than 254 characters. Previously, attempting to update a query which selected a long string column would result in an SQL error from DB2/2. ═══ Database administrator ═══ o The database administrator now supports columns of type LONG VARCHAR. Previously, selecting LONG VARCHAR as the column type would prevent you from applying the changes or closing the settings notebook. ═══ 5.2. New in version 2.1a ═══ What's new in version 2.1a: Design environment General Chart Editor Query Editor Runtime environment General Connection object Query object BoundObjects Chart object General BINDDBI Sample database generator Chart printing sample Database administrator ═══ General ═══ o Chart drag and drop coding Some minor errors in the drag and drop coding macros for chart objects were fixed. Also, the help buttons for these dialogs now work. o Bound objects drag and drop coding Objects that can be bound now provide drag and drop coding support for the Query and QueryColumns properties, plus their database related methods. o Personal REXX Previously, the database objects would not appear in the tool palette when using Personal REXX. Now they appear. ═══ Chart Editor ═══ o Charts in the chart gallery now accurately reflect their chart type. o Undoing a change, and then loading a new chart no longer causes the chart editor to crash. o Printer setup options now work. o Selecting Edit Chart from a chart's context menu when the chart editor is already open now brings the open chart editor to the front. o Pressing F1 for help in the chart editor and chart gallery now work. ═══ Query Editor ═══ o The query editor no longer leaves a blank line at the end of your Init and Fini sections when it is used. o The query editor now adds the calls to QRY_object_INIT and CNCT_object_INIT, and the QRY_object_FINI and CNCT_object_FINI in the correct order in the Init and Fini sections of your code. o The query editor no longer allows you to change the name of the query object to the name of an object that already exists. The name now must be unique. o An option has been added to the Query Editor to leave the connection open when it quits. This is an optimization so that opening the query editor repeatedly is faster. To turn this option on, check the Stay connected box in the Query Editor's Options window. Note that opening the Connection Editor always causes the connection to be closed regardless of the Stay connected setting. o If you are using a DB2/2 database but have not bound VX-REXX to the database, the SQL Editor now alerts you of this condition. Previously, it would not report the error until you tried to test the SQL statement. o Previously, the Query Editor would generate bound entry fields whose names contained blanks if the columns to which they were bound contained blanks in their names. The Query Editor now removes the blanks in the generated object names. ═══ General ═══ o Improved memory management 32Kb wide columns are supported and less memory is used for columns which are not completely filled (i.e. they contain less data than their column width allows). o Column data Previously column data would sometimes return incorrect values. This problem has been fixed. o Logon window The entry fields in the Connection object's logon dialog used to have a text limit of 32 characters. The limit is now 260 characters. ═══ Bound objects ═══ The following changes have been made to bound objects: o DescriptiveText objects You can now perform updates on queries that have descriptive text bound to them. Also, changing the Caption of a bound descriptive text object now notifies the query that data has changed. o Container object - If a bound container contains any user defined records when its query is opened, they are now deleted. Also, bound containers' DBDelete, DBInsert, DBReset, and DBUpdate now return correct error information through the VRError function even if the query object is invisible. - Calling the DBInsert method now refreshes the records in the container. Previously, the container was not refreshed. ═══ Connection object ═══ The following changes have been made to the connection object: o Logon prompting for DB2/2 If the Connection object is set to prompt if needed, and the password or userid are not set, the user is no longer prompted for these values if you are using DB2/2 and are already logged on, or if you are accessing an ODBC database that does not require these values. o ListColumns method - Previously column data would sometimes return incorrect values when using a remote DB2/2 or DB/2 database. This problem has been fixed. - Under Watcom SQL, columns with date information in them are no longer reported as containing timestamp information. They are reported as containing date information. Also, ListColumns now returns 0 when there were no columns found. The stem variable (e.g. Columns.) still reports that zero columns were found (i.e. Columns.0 = 0). o ListIndexes method The ListIndexes method would sometimes return a given index multiple times, with each occurrence containing only some of the columns in the index. Now indexes are returned correctly. o Rollback method Doing a rollback on a DB2/2 query now causes the query to be closed automatically. This avoids an error when trying to fetch a new record after a rollback. ═══ Query object ═══ The following changes have been made to the query object: o The number of open DB2/2 queries has been raised from 16 to 32. o Update method Previously, if you were to search on a column, and then change all matching rows so that they no longer fulfill the search parameters, and then invoke the Update method, an error would occur. Now the bound objects will be cleared, indicating an empty result table. ═══ Chart object ═══ The following changes have been made to the chart object: o The Y2 scale and the legend (if it is placed on the right) no longer intersect. o Changing the mouse pointer for the chart's parent window object now maintains that pointer when the mouse is over the chart object. o Setting the QueryDataFormat property to CrossTab when the chart data is not columnar now works. The chart object now works under the Japanese version of OS/2 (version 2.1J). ═══ BINDDBI.EXE ═══ The following changes have been made to the BINDDBI utility: o New command line parameters have been added to specify the time and date format, the type of record locking, and the isolation level. See the updated online Database Objects Guide for details. o BINDDBI should now work with older implementations of DB2 on MVS and AS/400 systems. ═══ Sample database generator ═══ o All column and table names in the sample database are now 8 charaters long or less. If you are upgrading from VX-REXX 2.1, you will have to recreate the sample database for the new sample programs to work. o The sample database generator can now add tables to remote databases. o Improved error checking has been added. ═══ Chart printing sample ═══ o The job properties dialog now saves job property information. This information is kept for each printer. ═══ Database administrator ═══ o When connecting to a newly created DB2/2 database, the userid and password fields are now initialized properly. o DB2/2 does not allow column names with mixed case, so the database administrator no longer accepts mixed case column names. o Decimal fields can now have a scale of 0. o Added a new refresh button to Privileges page that performs the same function as the reset button, except it is enabled before a change is made. o Foreign Key and Index Pages fields were added to the Table settings notebook. o The Help menu was improved, and complete context sensitive help was added. o Allows drag and drop foreign key creation. o The Primary Key page is now enabled for Watcom SQL databases. o Added Packages page to Table settings notebook to track package dependencies in DB2/2 databases. ═══ 6. Notices ═══ Copyright Disclaimer Trademarks ═══ Copyright ═══ Copyright 1994 by Watcom International Corporation All rights reserved. No part of this publication may be reproduced or used in any form or by any means -- graphic, electronic, or mechanical, including photocopying, recording, taping or information storage and retrieval systems -- without written permission of the Watcom International Corporation. ═══ Disclaimer ═══ Watcom (Watcom International Corporation and all of its subsidiaries) makes no representation or warranty with respect to the adequacy of this documentation or the programs which it describes for any particular purpose or with respect to its adequacy to produce any particular result. In no event shall Watcom, its employees, its contractors or the authors of this documentation be liable for special, direct, indirect or consequential damages, losses, costs, charges, claims, demands or claim for lost profits, fees or expenses of any nature or kind. ═══ Trademarks ═══ Watcom and VX-REXX are trademarks of Watcom International Corporation. IBM, OS/2, Extended Services, Extended Services for OS/2, Database 2, DB2/2, Multimedia Presentation Manager/2, and MMPM/2 are trademarks of the IBM Corporation. ═══ 7. Contacting Watcom ═══ How to Contact Watcom In North America (and all other non-European locations) Watcom International Corporation. 415 Phillip Street, Waterloo, Ontario, CANADA, N2L 3X2 General Inquiries Sales Technical Support tel: (519)886-3700 Upgrades, other product orders, hot-line: (519)886-3700 fax: (519)747-4971 and reseller inquiries/orders: fax: (519)747-4547 1-800-265-4555 (toll free in BBS: (519)884-2100 North America) Internet: tech@watcom.on.ca Compuserve: type GO WATCOM Watfax Technical support and product information is available 24 hours a day using our Watfax system. To reach Watfax, call 1-519-747-2693 from your touch-tone fax phone. In Europe Watcom Europe Limited. PO Box 64, Livingston, West Lothian, EH54 7AE, UNITED KINGDOM General Inquiries Sales Technical Support United Kingdom Upgrades, other product orders, United Kingdom tel: 0506 460112 and reseller inquiries/orders: tel: 0506 460112 fax: 0506 460115 fax: 0506 460115 United Kingdom Toll Free Other Locations tel: 0800 44 44 55 Other Locations tel: (44) 506 460112 fax: 0800 55 54 55 tel: (44) 506 460112 fax: (44) 506 460115 fax: (44) 506 460115 Germany Toll Free tel: 0130 81 88 62 BBS: (519)884-2100 fax: 0130 81 88 63 Internet: tech@watcom.on.ca Compuserve: type GO WATCOM France Toll Free tel: 05 90 81 35 fax: 05 90 81 36 All Other Locations tel: (44) 506 460112 fax: (44) 506 460115