11. WHERE Clauses in SQL
By: Jagan : 2007-10-12
Description: The WHERE clause in a SELECT statement provides the criteria for selecting values. For example, in the following code fragment, values will be selected only if they occur in a row in which the column Last_Name begins with the string 'Washington'.
Read the full article
12. Joins example in SQL
By: Kamini : 2007-10-12
Description: A distinguishing feature of relational databases is that it is possible to get data from more than one table in what is called a join. Suppose that after retrieving the names of employees who have company cars, one wanted to find out who has which car, including the make, model, and year of car. This information is stored in another table, Cars, shown in Table below.
Read the full article
13. Common SQL Commands
By: Lakshmi : 2007-10-12
Description: SQL commands are divided into categories, the two main ones being Data Manipulation Language (DML) commands and Data Definition Language (DDL) commands. DML commands deal with data, either retrieving it or modifying it to keep it up-to-date. DDL commands create or change tables and other database objects such as views and indexes.
Read the full article
14. Result Sets, Cursors and Transactions in SQL
By: Manoj Kumar : 2007-10-12
Description: When one user is accessing data in a database, another user may be accessing the same data at the same time. If, for instance, the first user is updating some columns in a table at the same time the second user is selecting columns from that same table, it is possible for the second user to get partly old data and partly updated data. For this reason, DBMSs use transactions to maintain data in a consistent state (data consistency) while allowing more than one user to access a database at the same time (data concurrency).
Read the full article
15. Stored Procedures example in SQL
By: Norman Chap : 2007-10-12
Description: A stored procedure is a group of SQL statements that can be called by name. In other words, it is executable code, a mini-program, that performs a particular task that can be invoked the same way one can call a function or method. Traditionally, stored procedures have been written in a DBMS-specific programming language. The latest generation of database products allows stored procedures to be written using the Java programming language and the JDBC API. Stored procedures written in the Java programming language are bytecode portable between DBMSs. Once a stored procedure is written, it can be used and reused because a DBMS that supports stored procedures will, as its name implies, store it in the database.
Read the full article
16. Getting Started with JDBC
By: Priya Mani : 2007-10-12
Description: This tutorial helps you to set up a JDBC™ development environment. This includes the following steps:
Read the full article
17. Using the DriverManager Class vs Using a DataSource Object for a connection
By: Reema Sen : 2007-10-12
Description: The DriverManager class works with the Driver interface to manage the set of drivers available to a JDBC client. When the client requests a connection and provides a URL, the DriverManager is responsible for finding a driver that recognizes the URL and for using it to connect to the corresponding data source. Connection URLs have the following form:
Read the full article
18. Creating Database Tables Using ANT
By: Sri Ganesh : 2007-10-12
Description: First, you can use a properties file to feed ANT, which has a simple sql target. Create a simple properties file, such as the one below:
Read the full article
19. PreparedStatement Example in Java
By: Tamil Selvan : 2007-10-12
Description: Sometimes it is more convenient to use a PreparedStatement object for sending SQL statements to the database. This special type of statement is derived from the more general class, Statement, that you already know.
Read the full article
20. JDBC and Tomcat context settings
By: Norman Chap : 2007-10-07
Description: JDBC is a standard part of Java and provides a uniform API that can be used to access any relational database. The low-level JDBC API is the foundation for the other database access technologies discussed in this chapter, but many programmers use the JDBC API directly. If your application has fairly limited database access needs, JDBC might be all you need. The advantages of JDBC are simplicity and flexibility. There are only about 25 classes and interfaces in JDBC, and for the most part, to use them you need to know only the basics of SQL. It’s simple. You execute queries and updates written in standard SQL, and each query returns a ResultSet object containing the resulting rows and columns of data. The JDBC API is simple, but it still provides the flexibility to do just about anything you’ll need to do with a database.
Read the full article

Previous      Next