1. Use a single JSP file to test the SYBASE jconnect-5_2 JDBC database interface:
2. Use JSP and Java Bean methods:
JSP Code:
3. Use JDBC (SYBAE jconnect-5_2) to query the data in Sybase ASA7.0 graphical Java program example:
//// A simple example of a graphical Java program that uses JDBC (SYBAE jconnect-5_2) to query
five employees to participate in the test. Only MySQL and Sybase were happy to go. IBM only promised to communicate via email and both Microsoft and Oracle refused to participate. Therefore, our database adjustment work on our behalf. During the test, we were surprised to find that the driver was the biggest source of the problem. Among the five tested databases, only 9i and MySQL can run Nile for 8 consecutive hours. The DB2 JDBC driver does not support updatable result sets, therefore, we can
Data | database
1. Test the Sybase jconnect-5_2 JDBC Database interface with one JSP file:
FFFF00 border=1>
2. Reuse the JSP and Java Bean methods:
JSP code:
3. Use JDBC (sybae jconnect-5_2) to query examples of graphical Java programs for data in Sybase ASA7.0:
A simple example of a graphical Java program using JDBC (sybae jconnect-5_2) to query data in Syb
Label:isql-dxxx-uxxx-p111111 connect the database with isql to discover that the database is not started. How do I start the Sybase database? [Ta_sybase] [/home/bta]su-sybase//Switch to Sybase user.Password:handsome[Email protected] ~]$ pwd/sdb1/sybaseDescription: SDB1 is the mount virtual machine disk.Sdb1/sybase/ase-12_5/install start Sybase under this path.[[email protected] ~]$ lsAse-12_5 ocs-12_5 sybase.csh _JVM data jconnect-5_5 media.inf sybcen
In actual Sybase ASE applications, especially in ASE + J2EE applications, set chained command not allowed within multi-statement transaction is easy to appear. (although ASE does not support the exception mechanism until version 15.0.1, This article uses the word "exception" for convenience ). Some developers think this is a problem with the Sybase Database; some think it is a problem to call the setautocommit () method multiple times; some developers think it is a problem with
You only need to keep the settings in the following places so that your JSP will not have any Chinese problems.1. charset of JSP2. Your jsp server uses the character set for compiling JSP. By default, it is the same as the operating system. You may need to modify3. the character set used during BEAN compilation is generally compiled using JAVAC, which is the same as that used in the operating system, but you can change it with parameters. If other programming tools can be used for compilation, y
The availability of cursors
Not all interfaces provide support for all cursor types.
ODBC and Ole DB (ADO) support all cursor types.
Embedded SQL supports all cursor types.
Ado. NET provides only forward-only, read-only cursors.
For JDBC
Jconnect 4.x only provides sensitive, unshaped cursors.
Jconnect 5.x supports all types of cursors, but scrollable cursors can cause significant performance degradat
Server.
4. DB2
High performance is suitable for data warehouses and online transaction processing.
V. Client Support and Application Mode
1. SQL Server
C/S structure, only supports windows customers, can be connected using ADO, Dao, oledb, ODBC.
2. Oracle
Multi-layer network computing supports multiple industrial standards and can be connected by network customers such as ODBC, JDBC, and OCI.
3. Sybase ASE
The C/S structure can be connected by network customers such as ODBC,
applies to data warehousing and online processing of things.
v. Client support and Application Mode
1. SQL Server
c/S structure, only support Windows customers, you can use ADO, DAO, OLE DB, ODBC connection.
2. Oracle
Multi-level network computing, supporting a variety of industrial standards, can use ODBC, JDBC, OCI and other network clients to connect.
3. Sybase ASE
c/S structure, you can use ODBC, Jconnect, Ct-library and other network customer co
Data | database
Java Connection Sybase DatabaseThe first step: 工欲善其事, its prerequisite. (Download driver)Download JDBC Driver:URL: http://www.sybase.com/detail?id=1009726There are two kinds of jConnect6.0 and jConnect5.5, we download 6.0 version.
Step two: Get the driveReleases the downloaded Jconnect-6_0.zip file, which has a folder: Devclasses, with a jar file jconn3d under it. We will also release Jconn3d.jar, in fact, we can not release, in order
a data-centric application, or as a network server in a multiuser client/server or a three-tier environment. As an embedded database system, it can be started automatically by the application as needed.
Although adaptive Server Anywhere is designed to emphasize simple management and modest resource requirements, it is still a scalable, high-performance DBMS. Adaptive Server Anywhere can run on multiple CPUs, has an advanced query optimizer, and provides performance monitoring and tuning tools.
(S1.getbytes ("iso-8859-1"), "GBK");
The GetBytes method is used to convert Chinese characters to "iso-8859-1" encoding into byte arrays, and "GBK" is the target encoding method. We read the Chinese string S1 from a iso-8859-1-encoded database, and through the above conversion process, the Chinese string S2 can be displayed correctly in the operating system and application software that supports the GBK character set.
surface analysis and treatment of Java Chinese problems
Background
Developm
In the past, it was necessary to set up a database connection pool with the help of third party software. But now NetBeans's Tomcat 5.5.7 and Sun application Server 8 can be set directly. Let's talk about how to set up under Tomcat 5.5.7.
1. Download the private connection driver for the database and copy it to the C:\Program Files\netbeans-4.1\enterprise1\jakarta-tomcat-5.5.7\common\lib folder below.
Suppose the database used is Sybase's adaptive Server Anywhere, download
The request processing engine is equivalent on both servers.
The programming interface application communicates with the database server using a programming interface. You can use ODBC, JDBC, OLE DB, Sybase Open Client, or Embedded SQL.
Many application development tools provide your own programming environment, which hides the details of the underlying interface. For example, if you use Sybase PowerBuilder to develop an application,
You never have to do an ODBC function call. However, in the
types of clients, such as CORBA, XML, HTML, DHTML, C + +, and any ActiveX clients, as well as PowerBuilder. Easerver also provides a single point of integration for heterogeneous backend systems that can extend customer business applications to the Web.
(There are many users using easerver, such as the University of California Online Museum, the middle tier is Easerver, through Sybase jConnect for JDBC connection to the background Sybase ASE databas
SQL Server, but concurrency on UNIX platforms is superior to SQL Server.4. DB2 performance is more suitable for data warehousing and online transaction processing.v. Client support and Application Mode1. SQL SERVERC/S structure, supported only for Windows customers, can be connected with ADO, DAO, OLE DB, ODBC. 2. Oracle Multi-level network computing, support a variety of industry standards, can be used in ODBC, JDBC, OCI and other network customers connect.3. Sybase asec/s structure, can be co
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.