home *** CD-ROM | disk | FTP | other *** search
/ Symantec Visual Cafe for Java 2.5 / symantec-visual-cafe-2.5-database-dev-edition.iso / DBServ / Readme.wri < prev    next >
Encoding:
Text File  |  1998-03-02  |  31.7 KB  |  760 lines

  1. README --  Symantec dbANYWHERE Server 1.1a for Windows 95/NT
  2.  
  3. Copyright (c) 1997 by Symantec Corporation. All Rights Reserved.
  4.  
  5. About This File
  6.  
  7. Welcome to Symantec dbANYWHERE Server for Windows 95/NT!  This file provides essential information concerning Symantec dbANYWHERE 
  8. Server for Windows 95/NT.  Please read this carefully before installing 
  9. the software.
  10.  
  11. This readme contains the following sections:
  12.  
  13. o  What's New
  14. o  Installation Notes
  15. o  NT Service Mode
  16. o  Sample Java Applications
  17. o  dbANYWHERE DataSource Configuration Utility
  18. o  dbANYWHERE Server and Database Engine Issues
  19. o  JDBC and JDK Specific Issues
  20. o  LongVarChar and LongVarBinary JDBC Datatypes
  21. o  Files Installed
  22. o  Where to Find More Information
  23. o  Questions, Bug Reports, and Other Feedback
  24.  
  25. _______________________________________________________________________
  26.  
  27. What's New
  28.  
  29. This release provides unlimited access to all the database drivers, including Oracle, Informix, Microsoft SQL Server, Sybase SQL Server, Sybase SQL Anywhere, Microsoft Access, and ODBC database drivers.  The release also provides major enhancements to error reporting, performance improvements to blob data, support for Symantec Visual Cafe for Java Database Development Edition (dbDE) 2.1 and later versions, as well as bug fixes.  Please refer to the on-line help and the "Symantec Installing and Running dbANYWHERE" book for more information.
  30.  
  31. 1. Improved error reporting and analysis
  32.  
  33. dbANYWHERE now provides detailed diagnostic information for error conditions, including suggestions whenever possible.  You can also customize the error messages to be displayed at server or client.  Please see the new Errors Property dialog in the Options Menu. 
  34.  
  35. 2. Enhanced blob performance
  36.  
  37. Large blob datatypes can now use a dedicated memory heap or temporary files for intermediate storage, subject to user configuration.  Please see the new Tuning Property dialog in the Options Menu.
  38.  
  39. 3. New Session constructor
  40.  
  41. If you have been using a previous version of dbANYWHERE API, please note
  42. that the constructor of symantec.itools.db.pro.Session has been changed
  43. to include an additional parameter:
  44.  
  45.     public Session (String serverURL, boolean designtime) 
  46.  
  47. The additional parameter specifies whether the Session object is instantiated at design time or run time, and is required to support the
  48. Symantec Visual Cafe development environment dbDE 2.1.  Please take the appropriate actions based on your current development environment:
  49.  
  50. a. If you are using Visual Cafe dbDE 2.1, please use the Migrate utility to automatically convert your existing project to use the new Session constructor.  
  51.  
  52. b. If you stay with previous versions of Visual Cafe, you do not need to make any changes to the Session constructor, however you will need to switch to a different Java API zip file.  Please see Installation Notes.
  53.  
  54. c. If you are not using Visual Cafe development environment, you will need to manually add an additional parameter when you instantiate the Session object.  Please be aware that existing applications or applets without the following change will not execute properly:
  55.  
  56.     new Session(serverURL,java.beans.Beans.isDesignTime())if JDK 1.1
  57. or
  58.      new Session(serverURL,false) if JDK 1.0.2
  59.  
  60.  
  61. 4. Closing of JDBC Objects  
  62.  
  63. It is recommended to close all the JDBC objects in your program when they are no longer in use.  They include Connection, Statement, PreparedStatement, CallableStatement, and ResultSet objects.  When those objects can no longer be referenced (e.g. out of scope in the program), dbANYWHERE will automatically close them, and all of their descendant objects.  For example, when the Connection object is closed, all the associated Statement and ResultSet objects will also be automatically closed.  All the associated resources will also be automatically freed.
  64.  
  65.  
  66. *  *  *  *  *
  67.  
  68. Installation Notes
  69.  
  70. dbANYWHERE Server provides several versions of Java APIs, to support 
  71. various releases of JDK and Symantec Visual Cafe development 
  72. environments.  They are located in the Redist directory as zip files:
  73.                               
  74. JDK version Development environment        APIs needed by Java client
  75. ----------- ------------------------------ -----------------------------
  76. JDK 1.0.2    Visual Cafe Pro 1.0x         dbaw_jdk102_vc10.zip/sql.zip
  77. JDK 1.1    Visual Cafe Pro 1.1          dbaw_jdk11_vc20.zip 
  78. JDK 1.1    Visual Cafe for Java dbDE 2.0     dbaw_jdk11_vc20.zip 
  79. JDK 1.0.2    Visual Cafe for Java dbDE 2.1     dbaw_jdk102_vc21.zip/sql.zip
  80. JDK 1.1    Visual Cafe for Java dbDE 2.1     dbaw_jdk11_vc21.zip 
  81.  
  82. dbaw.zip is a duplicate copy of dbaw_jdk11_vc21.zip, and is the default used in Visual Cafe for Java dbDE 2.1.  If you are using dbANYWHERE with  dbDE 2.1 and JDK 1.1, you do not need to make any changes to your installation. 
  83.  
  84. However, if you are using previous versions of Visual Cafe, or JDK, you will need to select the appropriate zip file(s) accordingly, and include it (them) in the class path of your Java client.  
  85.  
  86. For example, if you are using dbANYWHERE with JDK 1.1 and Visual Cafe for Java dbDE 2.0, you should:
  87. 1. Copy your dbANYWHERE Server\Redist\dbaw_jdk11_vc20.zip to your VisualCafedbDE\Java\Lib directory.
  88. 2. In your VisualCafedbDE\Java\Lib directory, remove the existing dbaw.zip, and rename the newly copied dbaw_jdk11_vc20.zip to dbaw.zip.  (Ensure your VisualCafedbDE\Bin\sc.ini includes CLASSPATH=...;%@P%\..\JAVA\LIB\DBAW.ZIP;....).
  89.  
  90. In JDK 1.0.2, browsers did not provide the necessary java.SQL package 
  91. needed for database connectivity. Attempting to provide this package 
  92. to the browser was not allowed for security reasons.  To avoid this 
  93. problem, a new package symjava.sql was provided. This package was contained in the file SQL.ZIP, and it duplicated the necessary java 
  94. functionality, but it required that all applets, applications and 
  95. components use the symjava.sql package when referring to classes such 
  96. as SQLException. With JDK 1.1, this problem has been resolved by 
  97. browsers. For this reason, the SQL.ZIP package is no longer necessary.
  98.  
  99. Previous versions of Visual Cafe Pro and dbANYWHERE provided the files 
  100. symantec.zip and dbaw_awt.zip. These files are no longer necessary, 
  101. and have been replaced with dbaw_awt.jar.  Please make sure your 
  102. classpath and sc.ini files properly reflect this change. If you do 
  103. not, you may experience "client/server mismatch" errors. In general, 
  104. this is all handled by the installation utilities, but is worthy of 
  105. note.
  106.  
  107.  
  108. *  *  *  *  *
  109.      
  110. NT Service Mode 
  111.  
  112. Note that NT Service mode for dbANYWHERE is available only for Windows 
  113. NT 3.51 and 4.0 versions. Make sure the dbANYWHERE Server is not 
  114. running and launch the dbANYWHERE Service Manager. Select the Install 
  115. As Service menu item from the Options menu. dbANYWHERE Service can now 
  116. be invoked by the Start button.
  117.  
  118.  
  119. *  *  *  *  *
  120.  
  121. Sample Java Applications
  122.  
  123. A set of sample Java applications have been included on the 
  124. installation CD that demonstrate typical uses of JDBC for accessing 
  125. data from databases, as well as cataloging information from databases. 
  126. The purpose of each Java code module is stated at the top of the code 
  127. in a comments section, along with other information about the code.
  128.  
  129. NOTE: These samples are not automatically installed. You must copy them 
  130. from the CD.
  131.  
  132. The sample applications are intended to give you a sense of how JDBC is 
  133. used to communicate with databases across the Internet/Intranet.  Some 
  134. of them are designed to work with the Sybase SQL Anywhere sample 
  135. database.  If you do not have the necessary database tables used by 
  136. these applications, feel free to modify the code to use whatever 
  137. database tables you have access to.
  138.  
  139. In order to access the Sybase SQL Anywhere Professional sample database,
  140. you will need to have TCP/IP installed on your machine.  The JDBC 
  141. samples are coded to connect to the local machine, with the use of the 
  142. TCP/IP key word, "localhost". This must be changed within the sample 
  143. code, if you wish to test against dbANYWHERE running on a remote 
  144. machine. (NOTE: In typical 3-Tier implementation, you would have 
  145. dbANYWHERE Server running on a separate machine from your databases and
  146. your client machines.  However, you can place any of these three tiers 
  147. on the same machine.  In our JDBC samples, we have assumed that you will 
  148. have all 3 tiers on the same machine.)
  149.  
  150. Symantec cannot promise that the sample applications provided will run 
  151. on your particular system.  We have tested them to assure that they 
  152. will build correctly and launch in the Symantec Cafe environment.  You 
  153. will probably need to alter the sample code to use your particular 
  154. TCP/IP addresses and database configurations. 
  155.  
  156. The installation CD contains all of the necessary files, along with a 
  157. document describing them in detail.  You will find the following 
  158. applets/applications included:  Customer, Employees, Expenses, 
  159. Inventory, Orders, PhoneBook, jdbcCall, jdbcDML, jdbcReadBlob, 
  160. jdbcShell, and jdbcViewer.  The samples with the "jdbc" name prefix 
  161. have been nicely organized in an object oriented fashion, extending 
  162. parent classes whenever possible.
  163.  
  164.  
  165. *  *  *  *  *
  166.  
  167. dbANYWHERE DataSource Configuration Utility
  168.  
  169. The DataSource Tool is a Java application which is used to register and 
  170. control data sources for access through dbANYWHERE Server.
  171.  
  172. To start using this program, click on the Configure DataSources icon in 
  173. the dbANYWHERE Server program group.  The DataSource Tool program will 
  174. be launched as a Java application.  You will have the option to edit 
  175. and delete existing data sources, as well as create new entries.  For 
  176. your convenience, there is a Test function that performs a quick 
  177. connect/disconnect for the data source selected using either the JDBC 
  178. API or dbANYWHERE API.  This way you can check to see if a current 
  179. entry specifies a valid, available database.  Likewise, you can also 
  180. perform connection tests for current data sources through the DSNTEST 
  181. function on the dbANYWHERE Server console.  For more information, 
  182. please consult the dbANYWHERE on-line help.
  183.  
  184. Note: The DataSource Tool application is provided as a convenient means 
  185. of editing the DBAWDSN.INI file.  It is provided as an aid, not as a 
  186. product itself.  For this reason, the program is distributed as is, 
  187. with no implied warranties or support.  Symantec may provide later 
  188. versions in the future, for download from the Symantec public Web site.
  189.  
  190.  
  191. *  *  *  *  *
  192.  
  193. dbANYWHERE Server and Database Engine Issues
  194.  
  195. 1. "Client/server mismatch" errors will be experienced with dbANYWHERE 
  196. if you have conflicting versions of the classes on the client and 
  197. server.  This may only be experienced if an earlier version of the 
  198. server was used or you are trying to use Visual Cafe Database 
  199. Development Edition with dbANYWHERE Server, without having updated the 
  200. classes on the client.  Please read the Installation Notes section of 
  201. this file for further details.
  202.  
  203. 2. dbANYWHERE Server should reside on the http server from which the 
  204. applet is being downloaded from if you wish to run dynamically 
  205. downloaded applets.  Since dbANYWHERE Server runs only on Windows NT 
  206. and Windows '95 platforms, http software for Windows NT or Windows 95 
  207. must be installed.  Applets can be run via Java's applet viewer, and 
  208. applications can run independently of browsers.  This is a Java security 
  209. restriction, not one imposed by dbANYWHERE Server.
  210.  
  211. 3. Sybase SQL Anywhere
  212.  
  213. a. Currently, there are datatype problems with the Sybase SQL 
  214. Anywhere 5.0 database engine, where precision numerics such as real, 
  215. float, and double experience data rounding for insert and update SQL 
  216. statements.  Thus, DML statements using these values in WHERE 
  217. clauses will fail on optimistic concurrency due to mismatches between 
  218. values in memory and the database.  You can verify this problem using 
  219. the ISQL utility and comparing values. Sybase is expected to produce 
  220. a fix for this in a later version.
  221.  
  222. b. For datatype mappings, dbANYWHERE will treat Real as a Float.  
  223. Although metadata functions will not return the exact datatype, 
  224. there will not be any DML problems as Real is a subset of the Float 
  225. datatype.
  226.  
  227. 4. Oracle
  228.  
  229. The Oracle driver currently does not support PL/SQL procedures which 
  230. use numeric datatypes as OUT parameters in callable statements.  Also, 
  231. the Oracle DATE datatype is mapped to TIMESTAMP.  SetDate will not 
  232. function, however you can alternatively use the SetTimestamp method.
  233.  
  234. 5. SQL Server / Sybase
  235.  
  236. a. These engines require the use of two DML statements for inserting 
  237. records into tables that include binary, varbinary, long varbinary,          and long varchar datatypes.  The first statement inserts a record       excluding values for these datatypes, then the second statement       performs an update to set these values and complete the transaction.     These columns must not have NOT NULL constraints, or else the       transaction will FAIL. Please note that NOT NULL is the default       constraint for columns defined in these database engines.
  238.  
  239. b. The maximum number of simultaneous open statements (dbprocesses) is 
  240. controlled by several factors, including the configuration parameter 
  241. MAXDBPROCESSES in dbANYWHERE, your database server license, and the 
  242. available virtual memory in your system.
  243.  
  244. The default MAXDBPROCESSES setting in dbANYWHERE is 3.  You can          modify the setting by following the steps below:
  245. - Edit the sample file provided with the installer (ddmssql.smp for              SQL Server, or ddsybase.smp for Sybase), and modify the setting                      (e.g. MAXDBPROCESSES=10).
  246. - Save the file as ddmssql.ini or ddsybase.ini.
  247. - Restart dbANYWHERE server for the change to take effect.
  248.  
  249. Please note that the MAXDBPROCESSES setting should never exceed what 
  250. your database server license allows.  Otherwise, significant time
  251. delay may be experienced on your first connection to database 
  252. through dbANYWHERE, as dbANYWHERE needs to find the actual license 
  253. limit.
  254.  
  255. The number of platform-dependent connections is also limited by the 
  256. amount of available memory.  MS SQL Server DB-Library will attempt 
  257. to allocate all of your available memory.  If your swap file is too 
  258. large, you may also experience significant time delay on your first 
  259. connection to MS SQL Server through dbANYWHERE.  If this occurs,
  260. you can consider reducing the size of your swap file.
  261.  
  262. The drivers for these engines do not observe the MINDBPROCESSES  
  263. setting defined in the driver INI files.  This means that when a 
  264. connection is opened, dbANYWHERE will not force the minimum number of 
  265. processes to be opened.  No negative impact should be experienced.
  266.  
  267. c. Using the JDBC statement object and issuing a SQL request which 
  268. produces result sets, requires the execution of a statement.Close()          or the completion of processing the result sets before reissuing          another SQL request using the same statement object.  Not doing this       may result in an error message due to results pending.  This is a          limitation enforced by the DbLIB client libraries to process all of       the results before issuing another SQL request.
  269.  
  270. d. Smalldatetime is currently not supported.  However, datetime is 
  271. fully supported and is a suitable substitute for the smalldatetime 
  272. datatype.
  273.  
  274. e. getBytes() and INOUT parameters are not supported.
  275.  
  276. 6. Informix
  277.  
  278. a. Informix INTERVAL datatype is mapped to JDBC VARCHAR data type.
  279.  
  280. b. For Informix FLOAT data type, dbANYWHERE rounds the scale (number of digits to the right of decimal point) to 6 digits.
  281.  
  282. 7. ODBC drivers
  283.  
  284. Intersolv ODBC drivers have trouble returning values for Time and 
  285. Timestamp using OUT and IN OUT parameters.  Microsoft ODBC drivers work
  286. for Timestamp but fail for Date and Time.  Contact your ODBC Driver 
  287. Vendor for assistance and updates.
  288.  
  289. 8. DML (data modification language)
  290.  
  291. a. If a table does not have a unique or primary key, any DML 
  292. statements generated that affect multiple rows will fail.  The only 
  293. recourse is to ensure that enough columns in the WHERE clause of the 
  294. DML statement are included to uniquely identify a record.
  295.  
  296. b. In some database engines, timestamps are special binary datatypes 
  297. that should not be modified or inserted by the user.  DML statements 
  298. will fail if binary timestamp values are used in the WHERE clause.
  299.  
  300. 9. dbANYWHERE API
  301.  
  302. a. Executing a stored procedure that returns multiple result sets is 
  303. currently not supported.
  304.  
  305. b. Single RelationView objects defined using SQL statements that 
  306. join two or more tables cannot be used for any DML operations. You 
  307. should only use one table per RelationView and bind RelationViews 
  308. together (this will give you the added power of the dbANYWHERE 
  309. API's database transaction logic).
  310.  
  311. c. Return values for stored procedures/functions are not supported, 
  312. when called in a format such as {? = call sp_returnvalue( ? )}.
  313.  
  314. d. dbANYWHERE API requires the database to support manual transactions (autocommit off).  If your database does not support transactions, you can only use dbANYWHERE API through native drivers, not ODBC drivers. 
  315.  
  316. 10. CallableStatement and PreparedStatement set and get methods for date, time, and timestamp have a variety of problems, specific to each 
  317. database driver. This is mostly due to limitations and/or bugs in the 
  318. ODBC driver, client libraries, or vendor DLLs.
  319.  
  320.  
  321.  
  322. *  *  *  *  *
  323.  
  324. JDBC and JDK Specific Issues
  325.  
  326. Note:  The JDBC 1.2 specifications and API references have been provided 
  327. on the installation CD.  These items are NOT automatically installed, 
  328. but have been included for your convenience under the jdbc_121 
  329. directory.
  330.  
  331. 1. Loss of Precision with java.lang.Double & java.lang.Float (JDK 1.0.2) 
  332.  
  333. Creating a java.lang.Double object with the Double( String ) constructor 
  334. can result in a loss of precision if the double value has more than 5 
  335. significant digits to the right of the decimal point (ROD).  Likewise, 
  336. calling Double.toString() will only return 5 digits ROD.
  337.  
  338. Example:
  339.  
  340. Double dbl = new Double( "1.123456789" );
  341. System.out.println( "Value = " + dbl.toString() ); // Value = 1.12346
  342. dbl = new Double( 1.123456789 );
  343. System.out.println( "Value = " + dbl.toString() ); // Value = 1.12346
  344.  
  345. Users of dbANYWHERE and Visual Cafe Pro should be aware of these 
  346. limitations when writing Java Applets/Applications which retrieve 
  347. double and float datatype information from user input, either via the 
  348. console command-line or a Java GUI. These values are usually read in 
  349. as text strings and need to be stored using the Double and Float Java 
  350. objects (using Double( String )).
  351.  
  352. Alternative (use java.math.BigDecimal):
  353. BigDecimal bd= new BigDecimal("1.123456789");
  354. System.out.println("Value = " + bd.toString()); // Value = 1.123456789
  355.  
  356. Symantec has filed a bug/problem report with JavaSoft concerning these 
  357. issues. Please feel free to contact JavaSoft to express your feelings.
  358.  
  359. 2. java.math.BigDecimal Limitations  (JDK 1.0.2 & JDBC 1.2x)
  360.  
  361. The new java.math.BigDecimal class introduced in JDBC 1.2 has some 
  362. limitations that should be noted.  dbANYWHERE uses the BigDecimal class
  363. to store Numeric, Decimal, Double, Float and Real datatypes because of 
  364. the problems outlined in Section (A) above.  Fortunately, 
  365. BigDecimal.toString() returns all digits ROD and results in no loss of 
  366. precision.
  367.  
  368. BigDecimal throws a NumberFormatException if the string or double value
  369. passed into the constructor uses E-Notation. For example, 
  370. new BigDecimal( "3.865e+100" ) will not work.  Because of this reason, 
  371. values in this format using a Visual Cafe Pro 1.0 applet at design 
  372. time/runtime will fail.
  373.  
  374. 3. Release Notes for JDBC 1.21
  375.  
  376. (The following text is taken from the Release Notes published by 
  377. JavaSoft)
  378.  
  379. Notes on This Version of BigDecimal
  380.  
  381. This release provides versions of both java.math.BigDecimal and 
  382. java.math.BigInteger. The BigInteger implementation is a special 
  383. JDK 1.0.2 version which uses a Java long as its internal value. Its 
  384. purpose is to support the BigDecimal implementation. (In JDK 1.1 the 
  385. BigInteger implementation is the full version which uses native code 
  386. and actually supports extended precision integers.) The result is that 
  387. this version of BigDecimal inherits BigInteger's precision 
  388. restrictions.
  389.  
  390. The BigDecimal API differs from the earlier Bignum API in two major 
  391. areas:
  392.  
  393. * The rounding option is no longer a class static. Instead, BigDecimal 
  394.   retains all precision were possible. In methods where precision can be 
  395.   lost, a rounding option can be specified. For instance, the result of 
  396.   a multiply has a precision which is the sum of the input value's 
  397.   precisions.  Since there is no single answer for the precision of 
  398.   divide, both a rounding option and scale for the result can be 
  399.   specified.
  400.  
  401. * The security oriented integer operations have been removed.
  402.  
  403. BigDecimal's new treatment of precision combined with the precision 
  404. restrictions in this version of BigInteger result in some surprises:
  405.  
  406. * Multiplication operations will likely overflow if both values have 
  407.   greater than 8 digits of precision.
  408.  
  409. * Conversion of seemingly small doubles to BigDecimal will overflow 
  410.   (due to the inexact nature of the double representation they actually 
  411.   contain more precision than can be represented by BigDecimal). For 
  412.   instance, new BigDecimal(1234.56) throws an overflow exception; use 
  413.   new Bignum("1234.56").
  414.  
  415. JavaSoft states that the limitations listed in their Release Notes 
  416. will be fixed with the release of JDK 1.1
  417.  
  418. 4. java.util.Date and java.sql.Timestamp Limitations (JDK 1.0.2)
  419.  
  420. Both classes have a range limitation from 1-Jan-1970 to 31-Dec-2037. 
  421. If you are attempting to read or store dates outside of these values, 
  422. the Applet/Application will throw an exception and report a "Year 
  423. out-of-range" error.
  424.  
  425. For details, please see:
  426.  
  427. http://www.javasoft.com/products/jdk/1.0.2/KnownBugs.html#Util and 
  428. http://www.javasoft.com/products/jdk/1.0.2/rfe.html#Util.
  429.  
  430. 5. Entering Timestamp values using Visual Cafe Database Development
  431. Edition and dbANYWHERE
  432.  
  433. java.sql.Timestamp supports a 9 digit format for entering nanoseconds.
  434. dbANYWHERE currently only supports 3 digits for milliseconds.  Additional digits entered will be round to the nearest milliseconds.  For example, 13:20:34.9989 will be round up to 13:20:34.999.      
  435.  
  436. 6. JDBC Escape Clauses
  437.  
  438. dbANYWHERE supports scalar functions and Stored procedures.  It does not currently support the following SQL escape clauses:
  439. a. Time and Date literals
  440. b. LIKE escape characters
  441. c. Outer joins
  442.  
  443.  
  444. *  *  *  *  *
  445.  
  446. LongVarChar and LongVarBinary JDBC Datatypes
  447.  
  448. 1. Working with JDBC LongVarChar and LongVarBinary datatypes
  449.  
  450. JDBC LongVarChar datatype stores variable length character data and the
  451. maximum length it can store is database dependent.  JDBC LongVarBinary 
  452. is the equivalent of LongVarChar with the only difference being that 
  453. it can handle binary data.
  454.  
  455. dbANYWHERE maps these datatypes in different databases as follows:
  456.  
  457. Database                    Native DataType   JDBC DataType
  458. --------------------------     ---------------   -------------
  459. Sybase SQL AnyWhere/Watcom    LongVarChar       JDBC LongVarChar
  460.                       LongVarBinary     JDBC LongVarBinary
  461.  
  462. Oracle                  Long              JDBC LongVarChar
  463.                       Long Raw          JDBC LongVarBinary
  464.  
  465. Sybase                  Text              JDBC LongVarChar
  466.                   I    mage              JDBC LongVarBinary
  467.  
  468. Microsoft SQL Server          Text              JDBC LongVarChar
  469.                       Image              JDBC LongVarBinary
  470. Microsoft Access              Memo              JDBC LongVarChar
  471.                       OLE Object          JDBC LongVarBinary
  472.  
  473. 3rd Party ODBC drivers          SQL_LONGVARCHAR   JDBC LongVarChar
  474.                       SQL_LONGVARBINARY JDBC LongVarBinary
  475.  
  476. The JDBC specification defines getAsciiStream(), getBinaryStream() 
  477. methods to retrieve data and setAsciiStream(), setBinaryStream() 
  478. methods to input data into columns of these special datatypes.  For 
  479. more information about these methods refer to the JDBC Specification.
  480.  
  481. 2. Retrieving data from JDBC LongVarChar and JDBC LongVarBinary 
  482.  
  483. dbANYWHERE supports accessing data from JDBC LongVarChar and JDBC 
  484. LongVarBinary using getAsciiStream() and getBinaryStream() methods 
  485. respectively. Currently getUnicodeStream() is not fully supported and 
  486. using this method would still return the data as ASCII characters.
  487.  
  488. Sequence of steps:
  489.  
  490.   A) Create a statement object
  491.   B) Construct the SQL Query
  492.   C) Execute the Statement using executeQuery() or execute()
  493.   D) Get the ResultSet
  494.   E) Walk through the ResultSet and retrieve columns in the ResultSet 
  495.      depending on the datatype returned.  If the columns returned are 
  496.      either LongVarChar or LongVarBinary datatypes, create a 
  497.      java.io.InputStream object.  Depending on the type, use either 
  498.      getAsciiStream() or getBinaryStream() method to retrieve data in 
  499.      chunks.
  500.     
  501. 3. Setting data into JDBC LongVarChar and JDBC LongVarBinary
  502.  
  503. dbANYWHERE supports the setting of data into JDBC LongVarChar and JDBC 
  504. LongVarBinary using setAsciiStream() and setBinaryStream() methods 
  505. respectively.  setUnicodeStream() is currently not fully supported and 
  506. using this method would still set the data as ASCII characters.
  507.  
  508. Sequence of steps:
  509.  
  510.   A) Create the SQL Statement with placeholders.
  511.   B) Create a Prepared Statement object using the SQL Statement.
  512.   C) Use setXXX() methods to set the placeholders to data values. If 
  513.      the type is LongVarChar or LongVarBinary, create a 
  514.      java.io.InputStream object which already has the data to be sent 
  515.      to the database. Depending on the type, use either the 
  516.      setAsciiStream() or setBinaryStream() method to send the data to 
  517.      the database.
  518.   D) Use executeUpdate() or execute() to execute the SQL Statement.
  519.  
  520. 4. Limitations in Microsoft SQL Server and Sybase
  521.  
  522. dbANYWHERE enforces some limitations on inserting data into text and 
  523. image datatypes in Microsoft SQL Server and Sybase, which map to 
  524. LongVarChar and LongVarBinary JDBC data types.  These limitations are 
  525. imposed by the dbLibrary routines used to develop the drivers.  Data 
  526. manipulation for text and image datatypes in SQL Server/Sybase has to 
  527. be done by retrieving a text pointer/timestamp value.  To retrieve this value, a 
  528. SQL statement containing only the text/image column has to be issued to
  529. retrieve the text pointer/timestamp value, before changing data in 
  530. these columns.  dbANYWHERE hides all of these limitations from the 
  531. user, but does enforce the restriction that two separate SQL Statements
  532. be used.  One SQL Statement could be used to insert data for all of 
  533. the columns except for text/image datatypes and issue a second SQL 
  534. Statement to insert data for the text/image column(s) using an UPDATE 
  535. statement. 
  536.  
  537. For example:  "TextTable" contains the following columns:
  538.  
  539.     intfld     integer
  540.     charfld     char(30)
  541.     textfld     text
  542.  
  543. // Issue an insert with all columns except "text" datatype
  544. String sql = "insert into texttable(intfld,charfld) values(?,?)"; 
  545. PreparedStatement stmt = connection.prepareStatement(sql);
  546.  
  547. stmt.setInt(1, 10);
  548. stmt.setString(2, "Record1");
  549. stmt.executeUpdate();
  550. stmt.close();
  551.  
  552. // Issue an update with one column only, (ie) of "text" datatype
  553. String sql1 = "update texttable set textfld = ? where intfld = 10"; 
  554. PreparedStatement stmt1 = connection.prepareStatement(sql1);
  555.  
  556. // file1.txt contains the text data to be inserted into the column
  557. File f = new File("c:\\dbANYWHERE\\Samples\\WriteLargeData\\file1.txt");
  558. FileInputStream fInput = new FileInputStream(f); 
  559.  
  560. stmt1.setAsciiStream(1, fInput, f.length());
  561. stmt1.executeUpdate();
  562. stmt1.close();
  563.  
  564.  
  565. *  *  *  *  *
  566.  
  567. Files Installed
  568.  
  569. c:\dbANYWHERE Server
  570. |   Dsntool.bat
  571. |   Readme.wri
  572. |
  573. +---api_ref
  574. |   |   AZIndex.html
  575. |   |   common.methods.html
  576. |   |   custom-bullet.gif
  577. |   |   DatabaseReference.html
  578. |   |   db.pro.AutoDetail.html
  579. |   |   db.pro.ConnectionInfo.html
  580. |   |   db.pro.DataAccess.html
  581. |   |   db.pro.ListBinder.html
  582. |   |   db.pro.ListLink.html
  583. |   |   db.pro.Logon.html
  584. |   |   db.pro.MultiView.html
  585. |   |   db.pro.ProjBinder.html
  586. |   |   db.pro.Projection.html
  587. |   |   db.pro.ProjLink.html
  588. |   |   db.pro.Record.html
  589. |   |   db.pro.RecordLink.html
  590. |   |   db.pro.RelationView.html
  591. |   |   db.pro.RelationViewMData.html
  592. |   |   db.pro.Request.html
  593. |   |   db.pro.Session.html
  594. |   |   db.pro.SessionMetaData.html
  595. |   |   exceptions.html
  596. |   |   Hierarchy.html
  597. |   |   Logo.html
  598. |   |   Package.html
  599. |   |
  600. |   +---images
  601. |           alpha-ix.gif
  602. |           alpha_a.gif
  603. |           alpha_b.gif
  604. |           alpha_c.gif
  605. |           alpha_d.gif
  606. |           alpha_e.gif
  607. |           alpha_f.gif
  608. |           alpha_g.gif
  609. |           alpha_h.gif
  610. |           alpha_i.gif
  611. |           alpha_j.gif
  612. |           alpha_k.gif
  613. |           alpha_l.gif
  614. |           alpha_m.gif
  615. |           alpha_n.gif
  616. |           alpha_o.gif
  617. |           alpha_p.gif
  618. |           alpha_q.gif
  619. |           alpha_r.gif
  620. |           alpha_s.gif
  621. |           alpha_t.gif
  622. |           alpha_u.gif
  623. |           alpha_v.gif
  624. |           alpha_w.gif
  625. |           alpha_x.gif
  626. |           alpha_y.gif
  627. |           alpha_z.gif
  628. |           blank.gif
  629. |           class-ix.gif
  630. |           class.gif
  631. |           const-ix.gif
  632. |           const.gif
  633. |           custom-bullet.gif
  634. |           err-ix.gif
  635. |           err.gif
  636. |           excpt-ix.gif
  637. |           excpt.gif
  638. |           if-ix.gif
  639. |           if.gif
  640. |           logo.gif
  641. |           meth-ix.gif
  642. |           meth.gif
  643. |           pkg-ix.gif
  644. |           pkg.gif
  645. |           var-ix.gif
  646. |           var.gif
  647. |           warn-ix.gif
  648. |           warn.gif
  649. |
  650. +---Bin
  651. |       dbaw.cnt
  652. |       dbaw.hlp
  653. |       DBAW.LDF
  654. |       DBAWDM.DLL
  655. |       DBAWDRVR.INI
  656. |       DBAWDSN.SMP
  657. |       DBAWKRNL.DLL
  658. |       DBAWLIC.TXT
  659. |       dbawlicense.dll
  660. |       DBAWMGR.EXE
  661. |       DBAWNBR.DLL
  662. |       DBAWPERF.DLL
  663. |       DBAWPERF.PMW
  664. |       dbawprops.dll
  665. |       DBAWSERV.DLL
  666. |       dbawservice.exe
  667. |       DBAWSRVR.EXE
  668. |       DBAWUTL.DLL
  669. |       dbuninst.exe
  670. |       DDACCESS.DLL
  671. |       DDINFMX.DLL
  672. |       DDINFMX.SMP
  673. |       DDMSSQL.DLL
  674. |       DDMSSQL.SMP
  675. |       DDODBC.DLL
  676. |       DDORACLE.DLL
  677. |       DDSYBANY.DLL
  678. |       DDSYBASE.SMP
  679. |       DDSYBNT.DLL
  680. |       DDSYBWIN.DLL
  681. |       DeIsL1.isu
  682. |       HELPID.TXT
  683. |       ITLU.EXE
  684. |       LUCLEAN.EXE
  685. |       PERFREG.H
  686. |       PERFREG.INI
  687. |
  688. +---dsntool
  689. |       ChangeBox$SymAction.class
  690. |       ChangeBox$SymWindow.class
  691. |       ChangeBox.class
  692. |       DeleteBox$SymAction.class
  693. |       DeleteBox$SymWindow.class
  694. |       DeleteBox.class
  695. |       DSNTOOL$SymAction.class
  696. |       DSNTOOL$SymItem.class
  697. |       DSNTOOL$SymWindow.class
  698. |       DSNTOOL.class
  699. |       DSN_ENGINE.class
  700. |       MsgBox$SymAction.class
  701. |       MsgBox$SymWindow.class
  702. |       MsgBox.class
  703. |       TestBox$SymAction.class
  704. |       TestBox$SymWindow.class
  705. |       TestBox.class
  706. |
  707. +---java
  708. |   +---bin
  709. |   |       java.exe
  710. |   |       javai.dll
  711. |   |       net.dll
  712. |   |       winawt.dll
  713. |   |
  714. |   +---lib
  715. |           classes.zip
  716. |           symbeans.jar
  717. |
  718. +---redist
  719.     dbaw.zip  
  720.     dbaw_jdk102_vc10.zip
  721.     dbaw_jdk102_vc21.zip
  722.     dbaw_jdk11_vc20.zip
  723.     dbaw_jdk11_vc21.zip
  724.     sql.zip    
  725.  
  726.  
  727. *  *  *  *  *
  728.  
  729. Where to Find More Information
  730.  
  731. o For more information on the Java language and related issues:
  732.  
  733.    http://java.sun.com
  734.  
  735. o For more information on the Sun JDBC API: 
  736.  
  737.    http://splash.javasoft.com/jdbc
  738.  
  739. o For the latest Symantec dbANYWHERE developments, please visit our 
  740.   Web site:
  741.   
  742.  http://cafe.symantec.com
  743.  
  744.  
  745. *  *  *  *  *
  746.  
  747. Questions, Bug Reports, and Other Feedback
  748.  
  749. Please refer to the on-line help (Help menu -> Sending Feedback).  Details are provided on what information should be provided when reporting a problem.
  750.  
  751.  
  752. *  *  *  *  *
  753.  
  754.  
  755. Thank you for choosing dbANYWHERE Server as your Java data 
  756. connectivity solution!
  757.  
  758. Sincerely,
  759.  
  760. The Symantec Internet Tools/Database Technologies Team