Java Reference
In-Depth Information
Appendix: Structured Query
Language (SQL)
SQL is a language for communicating with relational databases and originates in
work carried out by IBM in the mid-1970s. Since then, both ANSI (the American
National Standards Institute) and the ISO (International Standards Organisation)
have attempted to produce an SQL standard, with SQL3 being the latest, but
most users still working with SQL2. Though each major database vendor adds
its own specifi c extensions to 'standard' SQL, the most commonly required SQL
statements are widely accepted, with little or no variation between vendors. In this
very brief introduction to SQL, it is only these common statements that are of con-
cern to us. Please note that there is much more to SQL than can be covered in this
brief introduction, but this coverage will enable you to understand the contents
of Chap. 7 and to create your own statements for the most common database manipu-
lation activities.
In what follows, the Sales database from the exercises at the end of Chap. 7 will
be used for illustration purposes. Recall that this database had a single table called
Stock . Here's table Stock containing some test data (Fig. A.1 ):
Fig. A.1 Test data contents of Stock.mdb
Search WWH ::




Custom Search