home *** CD-ROM | disk | FTP | other *** search
/ Chip 1997 April / Chip_1997-04_cd.bin / prezent / cb / data.z / READLINK.TXT < prev    next >
Text File  |  1997-01-15  |  28KB  |  750 lines

  1.  
  2. ============================================================
  3.    WELCOME TO BORLAND 32-BIT SQL LINKS 3.5 FOR WINDOWS 95/NT
  4.    ---------------------------------------------------------
  5.  
  6.  
  7. This file contains important, late-breaking information 
  8. about Borland SQL Links for Windows, including revisions 
  9. to the documentation.  Information in this file supersedes 
  10. information in the SQL Links documentation.
  11.  
  12.  
  13. TABLE OF CONTENTS
  14. -----------------
  15.  
  16. 1.  C++ Builder 1.0 NOTES
  17. 2.  INSTALLSHIELD EXPRESS NOTES
  18. 3.  TIPS FOR USING SQL LINKS
  19. 4.  KNOWN PROBLEMS
  20. 5.  INTERBASE SQL LINK DRIVER
  21. 6.  ORACLE SQL LINK DRIVER
  22. 7.  SYBASE SQL LINK DRIVER (DB-Lib)
  23. 8.  SYBASE SQL LINK DRIVER (CT-Lib)
  24. 9.  MICROSOFT SQL LINK DRIVER
  25. 10. DB2 SQL LINK DRIVER
  26. 11. INFORMIX SQL LINK DRIVER
  27.  
  28.  
  29. 1. C++ Builder 1.0 NOTES
  30. ========================
  31. ///do we have any????
  32.  
  33.  
  34. 2. INSTALLSHIELD EXPRESS NOTES
  35. ==============================
  36.  
  37. If you have the 16-bit BDE installed and in use on your machine,
  38. you won't see all the available SQL Links drivers when you try to
  39. set up aliases in InstallShield Express. To correct this,
  40.  
  41.   1. Start the 32-bit BDE Configuration Utility.
  42.   2. Note the name of the default .CFG file being used (listed in
  43.      the title bar).
  44.   3. Choose Options|Configure WIN3.1 to uncheck it.
  45.   4. Choose File|Save to update the Windows Registry.
  46.   5. Choose Options|Configure WIN3.1 again.
  47.   6. Choose File|Save As and type TEMP.CFG. When the Non-system
  48.      Configuration File dialog box appears, choose No.
  49.   7. Close the BDE Configuration Utility.
  50.   8. Copy TEMP.CFG over your default .CFG file.
  51.  
  52.  
  53. 3. TIPS FOR USING SQL LINKS
  54. ===========================
  55.  
  56. WHERE TO START
  57. --------------
  58. For information about configuring and connecting to SQL 
  59. servers, see the Help file SQLLNK32.HLP.
  60.  
  61. USING ALIASES WITHOUT SPECIFYING A LANGUAGE DRIVER
  62. --------------------------------------------------
  63. If no language driver is specified, the default language 
  64. driver is ASCII.  Language-specific processes like 
  65. character translation, sorting and table name validation
  66. will default to English rules.  For further information, see
  67. "Common SQL Links driver settings" and your driver's 
  68. "Connecting to..." sections of the SQLLNK32.HLP.
  69.  
  70. WORKING WITH LARGE TABLES
  71. -------------------------
  72. If you create data entry forms on large tables you might
  73. find some performance degradation, particularly if the user 
  74. is allowed to view unrestricted record sets. To help cut 
  75. down the load on your server and optimize server 
  76. performance try to write applications that access relatively 
  77. few records at a time.  One way to do this within a 
  78. form-based application is to create forms that order the 
  79. data by index and set range criteria to limit the record 
  80. set. (For example, instead of creating a form that displays 
  81. all orders for all customers, write your application to 
  82. limit the user's working selection by criteria such as 
  83. customer name, state, and area code.)
  84.  
  85. WORKING WITH "SNAPSHOTS"
  86. (TABLES WITHOUT A UNIQUE INDEX OR ROW ID)
  87. -----------------------------------------
  88. It is always better to use a table with a unique index if 
  89. possible. This allows for better control and performance.
  90. If you insert records into a "snapshot" table, you might
  91. need to close and reopen the table to see your additions.
  92.  
  93. SYNONYM AND CROSS DATABASE / CROSS SERVER TABLE ACCESS
  94. ------------------------------------------------------
  95. Oracle and Informix synonyms can now be accessed using
  96. DbiOpenTable and Live Queries. Tables on different
  97. databases or servers can also be accessed in the same way.
  98. For example, you can now open "SCOTT"."CUSTOMER"@"DBLINK"
  99. on Oracle and pubs.dbo.authors on Sybase.
  100.  
  101. UPDATING SNAPSHOTS
  102. (TABLES WITHOUT UNIQUE INDEX OR ROW ID)
  103. ---------------------------------------
  104. When working with a table that does not have
  105. a unique index or row ID, keep the following in mind:
  106.  
  107. - The SQL Links do not support record modifications 
  108.   and deletions on "snapshots" within an explicit 
  109.   client transaction.  Emptying tables is supported 
  110.   within an explicit client transaction, but rolling 
  111.   back such an operation does not update the internal 
  112.   record cache.
  113.  
  114. - To update the record cache, close the table and then
  115.   open it again.
  116.  
  117.  
  118. 4. KNOWN PROBLEMS
  119. =================
  120.  
  121. DB2 ON WINDOWS 95
  122. -----------------
  123. In Windows 95, you should catalog DB2 nodes using TCP/IP on the client, 
  124. such as 
  125.  
  126.     CATALOG TCP/IP NODE MYNODE ...
  127.  
  128. If you use the Microsoft IPX/SPX protocol, the protocol will hang when 
  129. metadata is retrieved. IBM reports that this is a Microsoft problem.
  130.  
  131. The DB2 SQL Links driver can only access servers in the Windows 95
  132. environment that are connected using TCP/IP.
  133.  
  134. INFORMIX-REFERENTIAL INTEGRITY
  135. ------------------------------
  136. The Informix SQL Links driver does not currently support referential 
  137. integrity. Support is planned for a future release of SQL Links.
  138.  
  139. ROLLBACKS AND INFORMIX LOGGING TABLES
  140. -------------------------------------
  141. Rolling back a transaction on an Informix Logging database
  142. invalidates the cursor. To avoid this, use ANSI databases or
  143. close the cursor after rolling back the transaction and
  144. reopen it.
  145.  
  146. SYBASE CT-LIB STORED PROCEDURES
  147. -------------------------------
  148. When ENABLE BCD is TRUE, stored procedures with MONEY fields
  149. fail to retrieve MONEY output parameters.
  150.  
  151. INFORMIX - DECIMAL AND MONEY PRECISION
  152. --------------------------------------
  153. DECIMAL and MONEY data types are rounded to two decimal
  154. places when getting data from the server. For example,
  155. DECIMAL 123.4567 is rounded to 123.45. This is a vendor
  156. issue. To prevent this, set ENABLE BCD to TRUE in the BDE
  157. Configuration Utility.
  158.  
  159. INFORMIX - APPLYING FILTERS
  160. ---------------------------
  161. Applying a filter on DECIMAL and MONEY fields in 
  162. Informix will fail, because the data types are all mapped 
  163. to the BDE logical type fldFLOAT. To avoid this, use 
  164. passthrough SQL.
  165.  
  166. UPDATABLE SQL QUERIES
  167. ---------------------
  168. Tables owned by another user must be qualified by owner
  169. name.  Use quotation marks around the entire qualified
  170. name, for example "OWNER"."TABLE".
  171.  
  172. INFORMIX - USING VERSION 7.2 WITH BLOB FIELDS
  173. ---------------------------------------------
  174. If you open a BLOB field on an Informix 7.2 server, trying to
  175. move to another record causes the server to crash. This is caused
  176. by an Informix problem. Reference case number 55155 when
  177. contacting Informix.
  178.  
  179. INSTALLSHIELD TEMPORARY DIRECTORIES IN WINDOWS NT
  180. -------------------------------------------------
  181. When installing the SQL Links under Windows NT, InstallShield 
  182. does not remove temporary directories named _ISTMPx.DIR, where 
  183. x is a number from 0 to 9. You must delete them manually.
  184.  
  185.  
  186. 5. INTERBASE SQL LINK DRIVER
  187. ============================
  188.  
  189. INTERBASE SQL LINK and LOCAL INTERBASE
  190. --------------------------------------
  191. InterBase SQL Link installs a subset of the InterBase vendor
  192. DLLs necessary for Local InterBase.  If you have an earlier
  193. version of Local InterBase on your computer when you install
  194. InterBase SQL Link, be sure to upgrade with the latest version.
  195.  
  196. STORED PROCEDURE AND PARAMETER BINDING
  197. --------------------------------------
  198. Trying to bind parameters to a SQL statement after a stored 
  199. procedure has been run results in a "Column Unknown" error when 
  200. DbiQPrepare is called.
  201.  
  202. SUPPORTED DATA TYPES
  203. --------------------
  204. The BDE now supports the InterBase 4.0 data types of NUMERIC and 
  205. DECIMAL.
  206.  
  207. INTERBASE INSTALLATION CHANGES
  208. ------------------------------
  209. When installing over existing copies of IB_LICEN.DAT and 
  210. INTRBASE.MSG, the SQL Links installation program copies 
  211. the files being overwritten to IB_LICEN.BOR and 
  212. INTRBASE.BOR. If the SQL Links are uninstalled, these files 
  213. are NOT restored automatically; you must restore them.
  214.  
  215.  
  216. 6. ORACLE DRIVER
  217. ================
  218.  
  219. SUPPORT FOR QUOTED OBJECT NAMES
  220. -------------------------------
  221. This release of SQL Links supports the creation of Oracle
  222. tables with quoted object names.  Object names enclosed
  223. in double quotation marks may contain spaces, special
  224. characters, reserved words, or mixed case.  When querying
  225. a table with special object names, be sure to enclose the
  226. name in double quotation marks. For example:
  227.  
  228.      SELECT * FROM "Customer"
  229.  
  230. For more information on object naming rules, see your 
  231. Oracle server documentation.
  232.  
  233. USING LIVE QUERIES WITH QUOTED FIELD NAMES
  234. ------------------------------------------
  235. Live queries for Oracle tables require a table qualifier or 
  236. an alias name if the field names are quoted. For example :
  237.  
  238.     SELECT * FROM someTable WHERE "fieldname" = someValue
  239.  
  240. will not work, the workaround will be to use either
  241.  
  242.     SELECT * FROM someTable T1 WHERE T1."fieldname" = someValue
  243. or
  244.     SELECT * FROM someTable WHERE "someTable"."fieldname" = someValue
  245.  
  246. SETTING ORACLE DRIVER FLAGS
  247. ---------------------------
  248. Using mixed-case object names can result in incompatibility
  249. with earlier versions of SQL Links for Oracle. Earlier
  250. versions of SQL Links used uppercase object names only. To
  251. use uppercase object names only, set the DRIVER FLAGS option
  252. to 1 using the BDE Configuration Utility.
  253.  
  254. Specifying a Repeatable Read transaction isolation level
  255. can result in incompatibility with applications using earlier 
  256. versions of SQL Links for Oracle. Earlier versions of SQL 
  257. Links supported Read Committed only. To maintain transaction 
  258. support compatibility with earlier versions of SQL Links, use
  259. the BDE Configuration Utility to set the DRIVER FLAGS option
  260. to 512.
  261.  
  262. To use uppercase object names only AND maintain transaction 
  263. support compatibility with earlier versions of SQL Links, use
  264. the BDE Configuration Utility to set the DRIVER FLAGS option
  265. to 513 (representing 512+1).
  266.  
  267. ORACLE UPDATABLE QUERIES
  268. ------------------------
  269. All names, both column and table,
  270. are case sensitive (as if they were quoted explicitly).
  271.  
  272. ORACLE BLOCK WRITE SUPPORT
  273. --------------------------
  274. Support for Oracle array binding
  275. in this release shows improved performance for block writes
  276. when using DbiBatchMove and DbiWriteBlock.
  277.  
  278. CONFIGURING BDE FOR USE WITH ORACLE SQL*NET V2.0 OR GREATER
  279. -----------------------------------------------------------
  280. Use the BDE configuration utility (or alias manager) to set
  281. the "Net Protocol" parameter for Oracle aliases to TNS.
  282.  
  283.  
  284. 7. SYBASE DRIVER (DB-LIB)
  285. =========================
  286.  
  287. ADDITIONAL TRANSACTION ISOLATION LEVEL SUPPORT
  288. ----------------------------------------------
  289. An error (DBIERR_NOTSUPPORTED) is returned if
  290. Repeatable Read is specified.
  291.  
  292. USING DEFAULT SYBASE DRIVER FLAGS SETTING
  293. -----------------------------------------
  294. For Sybase SQL Servers prior to System 10, if your SQL 
  295. Server faults while executing BLOB reads or BLOB writes, 
  296. check the SQL Link driver's DRIVER FLAGS parameter.  If 
  297. DRIVER FLAGS is set to 0 (the Sybase default):
  298.  
  299.   1.  Call Sybase Customer Support and describe the 
  300.       problem, referencing Case #125046.
  301.  
  302.   2.  Set the DRIVER FLAGS parameter to 1.  Use this 
  303.       DRIVER FLAGS setting until you receive the necessary
  304.       software fix from Sybase.
  305.  
  306. Setting DRIVER FLAGS to 1 will enable you to execute BLOB 
  307. reads and BLOB writes without causing a server fault.  
  308. This may cause the client to receive SQL Server timeouts 
  309. during BLOB writes.
  310.  
  311. MULTIPLE RESULT SETS
  312. --------------------
  313. The Sybase SQL Link driver does not support the use of
  314. stored procedures that return multiple answer sets.
  315.  
  316. SYBASE INDEX HINT FOR UPDATABLE QUERIES
  317. ---------------------------------------
  318. This release of SQL Link has added support for Sybase's
  319. forceindex hint for query optimization when performing
  320. updatable queries. For example, the following query is
  321. now a valid updatable query:
  322.    SELECT * FROM CUSTOMER (2)
  323.  
  324. SYBASE URGENT PARAMETER AND TABLE CLOSE PERFORMANCE
  325. ---------------------------------------------------
  326. The use of the URGENT parameter is supported by the named
  327. pipes driver, the Novell NetWare networking software
  328. (SPX/IPX) as well as many TCP/IP networking packages:
  329. (Note: the dll's specified in the following examples are
  330. network and network transport specific.)
  331.  
  332. myNLMsrvr=C:\SQL\BIN\WDBNOVSP,04200020,1,83BD,URGENT
  333. myUNIXsrvr=C:\SQL\BIN\WDBNOVTC, 128.0.168.245, 1425, URGENT
  334. myNamedPipesrvr=C:\SQL\BIN\DLL_NAME,\\MY_SRVR\ROOT, URGENT
  335.  
  336. The  Sybase Open Client documentation erroneously notes that
  337. Novell's LanWorkPlace does not support the URGENT parameter.
  338. You actually need a LanWorkPlace version later than 4.0, Lan 
  339. WorkPlace for OS/2 is compatible only with version 3.0.
  340.  
  341. URGENT requires Out of Band Data (OOBD) support and is
  342. necessary for Sybase's  dbcancel() to work effectively.  
  343. Dbcancel() is called to cancel the retrieval of un-read
  344. result sets.
  345.  
  346. In order to properly support OOBD, your Solaris-based
  347. server may need a call to ndd to set its
  348. tcp_rexmit_interval_max parm.
  349. The call is:
  350.  
  351. /usr/sbin/ndd -set /dev/tcp tcp_rexmit_interval_max nnnn
  352.  
  353. where nnnn is a number of milliseconds.
  354.  
  355. You might see a delay when clicking on the master grid of
  356. a master-detail form - the query to retrieve the data for
  357. the detail might not return for several minutes.
  358.  
  359. By default, the TCP protocol will wait until a packet is
  360. full before sending it. This will generally help packet
  361. transmission over large networks because it cuts down on
  362. the number of packets sent. This can often slow the
  363. performance of client applications. If the server needs
  364. to send 750 bytes to an application and is using 512-byte
  365. packets, the client will see a delay while the server waits
  366. on 274 bytes of additional data.
  367.  
  368. It might be possible to disable this on the SQL Server
  369. itself.  This can be done by adding a trace flag to the
  370. RUN_SERVER file, -T1610.
  371.  
  372. UPDATE/DELETE QUERIES AND DBIGETRELATIVERECORD
  373. ----------------------------------------------
  374. Running the SQL statements UPDATE or DELETE on a table with a unique 
  375. index, closing and reopening the table, switching to an existing 
  376. index, then calling DbiGetRelativeRecord results in the server 
  377. error "Attempt to initiate a new SQL operation with results pending."
  378.  
  379. STORED PROCEDURES AND DBIQSETPROCPARAMS
  380. ---------------------------------------
  381. If a stored procedure with a result set and either an output
  382. parameter or a return value is executed and then rebound using
  383. a call to DbiQSetProcParams, the output parameter or return
  384. value will not work correctly.
  385.  
  386. SPECIFYING THE SYBASE QUERY API
  387. -------------------------------
  388. By default, SQL statements sent to MS SQL and Sybase servers
  389. using  DB-Lib are now sent using the synchronous query submission
  390. API. Earlier versions of SQL Links used the asynchronous query
  391. submission API. To use the asynchronous query submission API, add
  392. 2048 to the current value of DRIVER FLAGS or set it to 2048 if
  393. it's blank.
  394.  
  395.  
  396. 8. SYBASE DRIVER (CT-LIB)
  397. =========================
  398.  
  399. DBIERR_MULTIPLEUNIQRECS ON DEAD TABLES
  400. --------------------------------------
  401. If the error DBIERR_MULTIPLEUNIQRECS occurs while using 
  402. a dead table (no index at all), then the cursor for that 
  403. table should be closed and reopened, regardless of whether 
  404. DbiBeginTran had been called to start a transaction. This 
  405. is true only for the CT-Lib version of the Sybase driver.
  406.  
  407. SUPPORTING OLDER SYBASE SQL SERVER VERSIONS
  408. -------------------------------------------
  409. The Sybase CT-Lib driver does not support older versions
  410. of the Sybase SQL Server. If you intend to use Sybase 
  411. SQL Server versions 4.x and below, you must use the BDE 
  412. Configuration Utility (on the Sybase Driver page) to 
  413. change the name of the DLL32 parameter from SQLSSC32.DLL 
  414. (the default) to SQLSYB32.DLL. If you cannot find the 
  415. SQLSYB32.DLL file then you will need to run the Install
  416. program and select the Sybase DBLIB driver to install. 
  417. You will also need to set the environment variables PATH,
  418. SYBASE, INCLUDE and LIB so that they do not refer to the
  419. CT-Lib directory.
  420.  
  421. MULTIPLE ACTIVE STORED PROCEDURE SUPPORT
  422. ----------------------------------------
  423. The Sybase CT-Lib SQL Link driver can now perform row
  424. fetches from multiple stored procedures simultaneously using
  425. the new property stmtEXECASCURSOR.
  426.  
  427. The stmtEXECASCURSOR property allows users to ask for a CT-Lib
  428. cursor instead of  a CT-Lib command. CT-Lib cursors let the
  429. user have multiple cursors open and fetch rows from those
  430. simultaneously. With CT-Lib commands, all pending results
  431. must be processed before executing the next operation.
  432.  
  433. This property is mainly for users who execute Sybase stored
  434. procedures that return a result set. They can pass the SQL
  435. string as "EXECUTE proc_name"  or "EXECUTE proc_name  :1,
  436. :2, :3  ..." (if there are parameters), prepare the
  437. statement, then set stmtEXECASCURSOR to True. This makes the
  438. driver open cursors on the stored procedure instead of a
  439. command.
  440.  
  441. Some limitations to this property:
  442. 1.  The stored procedure should not have any BDE output
  443.     parameters or return status.
  444. 2.  Input parameters must be place holders in the SQL string
  445.     and  must be bound before execution. (Literal substitution
  446.     of parameter values in the string doesn't work).
  447. 3.  The stored procedure body should contain a single
  448.     SELECT statement returning a single result set.
  449.  
  450. EXAMPLE:
  451.  
  452.    int main ()
  453.    {
  454.        // Initialize engine
  455.        
  456.        // Connect to database
  457.    
  458.        //Prepare a statement
  459.        DbiQPrepare(hDb, .., .. , phStmt);
  460.     
  461.       // Set the property
  462.       DbiSetProp(hStmt,  stmtEXECASCURSOR, TRUE);
  463.    
  464.       // Bind parameters if any
  465.    
  466.       //DbiQExec(hStmt, phCur);
  467.    
  468.        .
  469.        .
  470.        .
  471.       
  472.         return 0;
  473.    }
  474.  
  475.  
  476. 9. MICROSOFT SQL DRIVER
  477. =======================
  478.  
  479. USING DEFAULT MICROSOFT SQL DRIVER FLAGS SETTING
  480. ------------------------------------------------
  481. If your Microsoft SQL Server faults while executing BLOB reads
  482. or BLOB writes, check the SQL Link driver's DRIVER FLAGS 
  483. parameter.  If DRIVER FLAGS is set to 0 (the Microsoft SQL 
  484. default) set the DRIVER FLAGS parameter to 1. Setting DRIVER 
  485. FLAGS to 1 will enable you to execute BLOB reads and BLOB 
  486. writes without causing a server fault. This may cause the 
  487. client to receive SQL Server timeouts during BLOB writes.
  488.  
  489. SPECIFYING THE MS SQL QUERY API
  490. -------------------------------
  491. By default, SQL statements sent to MS SQL and Sybase servers
  492. using  DB-Lib are now sent using the synchronous query submission
  493. API. Earlier versions of SQL Links used the asynchronous query
  494. submission API. To use the asynchronous query submission API, add
  495. 2048 to the current value of DRIVER FLAGS or set it to 2048 if
  496. it's blank.
  497.  
  498.  
  499. 10. DB2 DRIVER
  500. ==============
  501.  
  502. DBCLOB DATA TYPE
  503. ----------------
  504. The DB2 physical type DBCLOB is not currently supported 
  505. within the BDE even though schema information indicates 
  506. that it is an available type. It is suggested that you use 
  507. either CLOB or BLOB physical types.
  508.  
  509. STORED PROCEDURES
  510. -----------------
  511. The SQL Links driver for DB2 translates the logical BDE
  512. string type (fldZSTRING) to a physical DB2 SQL_CHAR data
  513. type when it is passed as a parameter to a stored procedure.
  514. This can cause problems for stored procedures that are
  515. hard-coded to expect a physical SQL_VARCHAR as a parameter. 
  516.  
  517. Programmers should write stored procedures that examine the
  518. sqltype member of the SQLDA structure (for example,
  519. input_sqlda->sqlvar[i].sqltype) to determine which data type
  520. the client has actually bound, instead of expecting a
  521. specific data type.
  522.  
  523. CONNECTING TO AS/400 SERVERS
  524. ----------------------------
  525. Due to a problem with IBM server software, remote
  526. connections to DB2 on the AS/400 platform do not work
  527. properly when version 2.1.0 or earlier of the DB2 
  528. client/server library is used. Version 2.1.1 of the 
  529. client/server library corrects the problem.
  530.  
  531. CREATING INDEXES ON AS/400 SERVERS
  532. ----------------------------------
  533. Due to a problem with the IBM server software version 
  534. 2.1.1, if you create a new index by specifying an index 
  535. name that includes lowercase characters and is enclosed 
  536. in double quotes ("<index_name>"), the index cannot be 
  537. accessed by the BDE.
  538.  
  539. For example, the following statement creates an 
  540. accessible index, 
  541.  
  542.    CREATE INDEX CustNdx ON ....
  543.  
  544. but the following statement creates an index that the 
  545. BDE can't access,
  546.  
  547.    CREATE INDEX "CustNdx" ON ....
  548.  
  549. If creating an index through a call to DbiAddIndex(), the
  550. szName member in the IDXDesc Parameter should only be
  551. uppercase.
  552.  
  553. CREATING BLOB OR CLOB COLUMNS WITH DBICREATETABLE()
  554. ---------------------------------------------------
  555. When using DbiCreateTable(), BLOB or CLOB columns created in
  556. a DB2 table by the function are set by default to a size of
  557. 1MB. To create BLOB columns of different sizes, use
  558. Passthrough SQL.
  559.  
  560. VARBINARY OUTPUT PARAMETERS IN STORED PROCEDURES
  561. ------------------------------------------------
  562. In a stored procedure parameter description
  563. (SPParamDesc.uFldType), normally a corresponding BDE logical
  564. data type is specified. There is one exception. A varbinary
  565. output parameter should specify fldBYTES instead of
  566. fldVARBYTES.
  567.  
  568. CALLING BY NAME IN STORED PROCEDURES
  569. ------------------------------------
  570. DB2 only supports calling by number in stored procedures.
  571. Always use calling by number instead of calling by name.
  572.  
  573. CREATING SCHEMA OBJECTS ON IBM MVS
  574. ----------------------------------
  575. There is an optional entry, within the alias settings of the 
  576. BDE configuration, called REMOTE DBN. This entry can be used 
  577. for setting the user's preferred database on IBM MVS. For 
  578. creating Schema objects using APIs like DbiCreateTable() 
  579. this entry should be set to the user's preferred database 
  580. name. This entry is only used for IBM MVS.
  581.  
  582. For example; REMOTE DBN = BORLAND will create objects in 
  583. database BORLAND and the query generated by  BDE will be 
  584. "CREATE TABLE TABNAME ( ... ) IN DATABASE BORLAND". 
  585.  
  586. Ignoring this entry will create objects in the user's 
  587. default database.
  588.  
  589.  
  590. 11. INFORMIX DRIVER
  591. ===================
  592.  
  593. SOFTWARE REQUIREMENTS
  594. ---------------------
  595. The Informix SQL Link driver requires the latest client
  596. software from Informix.
  597.  
  598. LIMITATIONS ON OPENING TABLES
  599. -----------------------------
  600. This edition of the Informix SQL Link driver does not
  601. support opening a table with a column name that is an
  602. Informix keyword or function name. Some examples include
  603. MONTH, DAY, YEAR, AVG, COUNT, ALL, and UNIQUE.
  604.  
  605. For a complete list of keywords and function names, see 
  606. your Informix documentation.
  607.  
  608. COPYING INFORMIX TABLE WITH INTERVAL COLUMN
  609. -------------------------------------------
  610. When an Informix table with an interval column is copied,
  611. the destination table is created with an interval that has
  612. a qualifier of year-to-month. If this qualifier does not 
  613. match the source table's interval qualifier, you will 
  614. receive an error during the copy.
  615.  
  616. To work around this problem, use passthrough SQL to 
  617. create the destination table with the correct interval 
  618. qualifier. Then append the contents of the source table 
  619. to the destination table.
  620.  
  621. STORED PROCEDURE SUPPORT
  622. ------------------------
  623. The Informix driver supports stored procedures. 
  624. Please note the following points:
  625.  
  626. 1. Informix stored procedures have input parameters but
  627.    no output parameters.
  628.  
  629. 2. DbiOpenSPParamList returns all input parameters
  630.    and sets SPParamDesc.uParamNum and SPParamDesc.szName
  631.    starting from 1. 
  632.  
  633.       SPParamDesc[0].uParamNum = 1
  634.       SPParamDesc[0].szName = "1"
  635.      and SPParamDesc[0].eParamType = paramIN;
  636.       .
  637.       .
  638.       .
  639.   
  640.    The rest of the information for SPParamDescs
  641.    (such as uFldType, usubType, iUnits1, iUnits2, uOffset,
  642.     uLen, and uNullOffset) must be set by user.
  643.  
  644. RETRIEVING SQLCA INFORMATION
  645. ----------------------------
  646. The Informix SQL Link driver includes an improved
  647. passthrough property that contains native SQLCA information.
  648. Users can use the drvNATIVESQLCA property with DbiGetProp()
  649. to retrieve SQLCA information. 
  650.  
  651. SQLCA information gives detailed data on Informix server
  652. errors and exceptions. When an Informix error occurs, the
  653. Informix Global SQLCA information for that error is
  654. retrieved and retained by the SQL driver until the next time
  655. the database server is accessed. General SQLCA information
  656. is returned whenever an error hasn't occurred.
  657.  
  658. The following table shows the information that is made available.
  659.  
  660.                   *ppropValue        *pilen
  661. Informix          SQLCA              sizeof(struct sqlca_s)
  662.  
  663. EXAMPLE
  664.  
  665. // Informix SQLCA structure from informix sqlca.h header file
  666. struct sqlca_s
  667.      {
  668.      long sqlcode;
  669.      char sqlerrm[72]; /* error message parameters */
  670.      char sqlerrp[8];
  671.      long sqlerrd[6];
  672.                /* 0 - estimated number of rows returned */
  673.                /* 1 - serial value after insert or  ISAM error code */
  674.                /* 2 - number of rows processed */
  675.                /* 3 - estimated cost */
  676.                /* 4 - offset of the error into the SQL statement */
  677.                /* 5 - rowid after insert  */
  678.      struct sqlcaw_s
  679.      {
  680.      char sqlwarn0; /* = W if any of sqlwarn[1-7] = W */
  681.      char sqlwarn1; /* = W if any truncation occurred or
  682.                          database has transactions */
  683.      char sqlwarn2; /* = W if a null value returned or
  684.                          ANSI database */
  685.      char sqlwarn3; /* = W if no. in select list != no. in into list or
  686.                          turbo backend */
  687.      char sqlwarn4; /* = W if no where clause on prepared update,
  688.                          delete or incompatible float format */
  689.      char sqlwarn5; /* = W if non-ANSI statement */
  690.      char sqlwarn6; /* reserved */
  691.      char sqlwarn7; /* reserved */
  692.      } sqlwarn;
  693.      };
  694.  
  695. struct sqlca_s mySqlca;
  696.  
  697. int main()
  698. {
  699.      // Initialize engine
  700.  
  701.      // Connect to database.
  702.  
  703.       //get the sqlca (on no exception)
  704.       unsigned int len;
  705.       DbiGetProp(hDb,drvNATIVESQLCA, &mySqlca, sizeof(sqlca_s),
  706.                       &len);
  707.  
  708.      //get the sqlca (on an exception)
  709.       DbiOpenTable(hDb, "non existing table", ...)
  710.  
  711.       DbiGetProp(hDb,drvNATIVESQLCA, &mySqlca, sizeof(sqlca_s),
  712.                       &len);
  713.        return 0;
  714. }
  715.  
  716. SYSTEM TABLE STORAGE OF OBJECT NAMES
  717. ------------------------------------
  718. Before storing object names in the system tables (such as table
  719. names, index names, field names, and so on) the Informix driver
  720. converts them to lowercase.
  721.  
  722. RETRIEVING INFORMIX DATABASE INFORMATION
  723. ----------------------------------------
  724. The Informix SQL Link driver has three properties for determining 
  725. the type of database the BDE is connected to
  726.  
  727.    Property          Type     Description
  728.    ---------------------------------------------------------
  729.    dbONLINE          BOOL     TRUE if the database connected
  730.                               is ONLINE type otherwise FALSE
  731.    dbTRANALLOWED     BOOL     TRUE if the database connected
  732.                               permits transactions otherwise
  733.                               FALSE
  734.    dbANSI            BOOL     TRUE if the database connected
  735.                               is ANSI type otherwise FALSE
  736.  
  737. You can access these properties using the BDE function
  738. DbiGetProp.
  739.  
  740. INFORMIX - USING NATIONAL LANGUAGE SETTINGS
  741. -------------------------------------------
  742. If your Informix client software is set up to use German language 
  743. settings, extraneous data may be displayed in CHAR or VARCHAR
  744. fields. This is a problem with the client software and is being
  745. investigated with Informix.  A workaround is to set all national
  746. language parameters to blank using the Informix SETNET32 utility.
  747.  
  748. =================================================================
  749.  
  750.