Database Reference
In-Depth Information
describe and process such data structures. Because it involves two multivalued paths
through the data, SQL cannot be used to describe the data. Instead, we must execute
two SQL statements and somehow patch the results to obtain the view.
Views like that shown in Figure 11-61 have been processed for many years, but
only by private, proprietary means. Every time such a structure needs to be processed,
a developer designs programs for creating and manipulating the data in memory and
for saving them to the database. Object-oriented programmers define a class for this
data structure and create methods to serialize objects of this class into the database.
Other programmers use other means. The problem is that every time a different view is
designed, a different scheme must be designed and developed to process the new view.
As Microsoft developed .NET technology, it became clear that a generalized
means was needed to define and process database views and related structures.
Microsoft could have defined a new proprietary technology for this purpose, but thank-
fully it did not. Instead, it recognized that the concepts, techniques, and facilities used
to manage regular databases can be used to manage in-memory databases as well.
The benefit to you is that all of the concepts and techniques that you have learned to
this point for processing regular databases can also be used to process datasets.
DataSets do have a downside, and a serious one for some applications. Because DataSet
data are disconnected from the regular database, only optimistic locking can be used. The data
are read from the database, placed into the DataSet, and processed there. No attempt is made to
propagate changes in the DataSet back to the database. If, after processing, the application later
wants to save all of the DataSet data into a regular database, it needs to use optimistic locking. If
some other application has changed the data, either the DataSet will need to be reprocessed or
the data change will be forced onto the database, causing the lost update problem.
Thus, DataSets cannot be used for applications in which optimistic locking is problem-
atic. For such applications, the ADO.NET Command object should be used instead. But for
applications in which conflict is rare or for those in which reprocessing after conflict can be
accommodated, DataSets provide significant value.
By ThE WAy Combining Oracle Database with ASP.NET applications is somewhat com-
plex, and beyond the scope of this discussion. A good starting point is the
Oracle Database 2 Day + .NET Developer's Guide for Oracle Database 11 g Release 2
at http://docs.oracle.com/cd/E11882_01/appdev.112/e10767/toc.htm . In particular,
see Chapter 7 - Using ASP.NET with Oracle Database at http://docs.oracle.com/cd/
E11882_01/appdev.112/e10767/using_aspnt.htm .
By ThE WAy The only way to use Oracle Database XML facilities is to write in Java, an
object-oriented programming language. Further, the only way to process
ADO.NET is from one of the .NET languages, all of which, like Visual Basic .NET, are
object-oriented languages. Thus, if you do not yet know object-oriented design and pro-
gramming, and if you want to work in the emerging world of database processing, you
should run, not walk, to your nearest object-oriented design and programming class!
The Java Platform
Having looked at the Microsoft .NET Framework in some detail, we will now turn our atten-
tion to the Java platform and look at its components.
JDBC
Originally, and contrary to many sources, JDBC did not stand for Java Database Connectivity.
According to Sun Microsystems—the inventor of Java and the original source of many
 
 
Search WWH ::




Custom Search