Solo disponible en BuenasTareas
  • Páginas : 11 (2593 palabras )
  • Descarga(s) : 0
  • Publicado : 12 de enero de 2012
Leer documento completo
Vista previa del texto

An Advantage for Delphi Developers
By: Cary Jensen, Ph.D.


TABLE OF CONTENTS 1 2 Data Access in Delphi General Overview of the Advantage Database Server 2 Advantage is a Full-Featured Database 2 Advantage Comes in Many Flavors 2 An Easy to Use Data Architect 3 A Multitude of Data Access Options 3 Data Dictionaries with Database Wide Security 3 StoredProcedures, User Defined Functions and Views 3 Support for Constraints 3 Online Full and Incremental Backup 4 Database Replication 4 Triggers and Notifications 4 4 Conclusion About the Author


This article first appeared on Cary Jensen's blog at http://caryjensen. advantage-for-delphi-developers. html and is reprinted with permission of the author.

Here's a triviaquestion: What was the name of Delphi during its original beta test? The answer is Delphi (but you probably knew that already). But why did the Delphi development team pick such an odd name for their ground breaking, component-based heir to their Pascal development tool? The answer is related to databases. Delphi is name of both the city and temple in Greece where people would travel to speak to theOracle. And although Delphi can work with just about any database you can think of, the point was that it was designed from the beginning to be a great environment for developing database applications. It’s ironic, then, that while Delphi’s name alludes to ORACLE, one of the most popular SQL-based relational database management systems (RDBMS), the foundations of database access in Delphi isnavigational, not set oriented. Specifically, the original data access mechanism in Delphi was the Open Database Application Programming Interface, or ODAPI. ODAPI, which would later be referred to simply as the Borland Database Engine, or BDE, was a direct outgrowth of the Paradox Engine. The Paradox file format, like many of its file-based cousins, is index based. In other words, database tables aretreated as an ordered sequence of records (rows), whose order can be changed by changing which index is used to access the records. These indexes can also be used to filter records of a single table, as well as perform joins between tables having compatible indexes. DATA ACCESS IN DELPHI That Delphi’s database roots are well grounded in the navigational model is immediately obvious if you consider theTDataSet class, which is the base class for all data access components in Delphi. This class includes properties and methods for a variety of navigational operations. For example, for selecting indexes (IndexName), setting ranges (SetRange), finding records based on indexed values (FindKey, FindNearest), creating relational joins using indexes (MasterSource and MasterFields), and navigatingrecords in index order (First, Next, Prior, MoveBy, and so forth). While the benefits of SQL-based data access are well-known, navigational data access has its advantages as well. Specifically, the navigational model better suits the development of intuitive and user-friendly interfaces. For example, with a navigational interface, it is possible to display all of the records from a database table (or aquery result set), and permit the user to navigate these records freely. This navigation may even include incremental search (always an end user favorite). And, these features are available whether the underlying table has a couple of hundred records, or millions. By comparison, nearly all set-based databases, such as MS SQL Server and ORACLE, are not designed to provide navigational access. As aresult, searching for a record in a result set means refining an underlying WHERE clause in a SQL query to reduce the resulting result set to a manageable size. The idea of opening a result set with millions of records and permitting a user to freely browse it is unthinkable. Here is where the Advantage Database Server really shines. Not only is it a high-performance, low maintenance database...
tracking img