In this chapter we will look at basic database application development.
In this chapter we will be looking at how database applications are built in client-server architectures. Client-server systems operate within a network. We have a front-end client and a back-end processor. There are two primary types of architectures: two-tiered architectures and three-tiered architectures.
In a two-tiered environment we have what are called “fat” clients. These computers contain the actual database applications, and can contain actual pieces of the database as well. The back-end servers contain the database, data dictionaries, etc. In a three-tiered architecture – we have “thin” clients. The thin client computers contain presentation logic that allows for input and output. The thin clients network to a middle layer of server that includes processing logic that includes I/O processing, business rules and data management. This middleware includes several classes of software that allow an application to interoperate with other software without the user understanding or needing to code the low-level operations required to achieve this interoperatility. These middleware products are called an application programming interface (API) and a database driver to connect to a specific type of database. The most common APIs are “Open Database Connectivity (ODBC)” and ADO.NET for Microsoft platforms, and Java Database Connectivity (JDBC0 for use with Java programs. The server includes storage logic of data storage and retrieval.
PARTITIONING AN APPLICATION
Many times it makes more sense to break up an application and partition it to either the client side or to one or more servers. This is usually done to bring the application closer to the “user” and save on network traffic.
WEB APPLICATION COMPONENTS
As we look at applications that are created to run on the web – we can use our traditional three-tiered architecture to explain how we would set up these applications. To create the web application site we use the three tiered architecture plus web functionality:
LANGUGAGES FOR CREATING WEB PAGES
The World Wide Web Consortium (W3C) is the chief standards body for HTTP and HTML. The W3C is an international consortium of companies. It develops standards for companies to use to create Web products.
HTML – Hypertext Markup Language is the fundamental authoring language to create documents for the web. HTML is a scripting language intended to define Web document structure and layout for display purposes that uses tags and attributes.
XML – also a scripting language used to capture data structures. It stands for Extensible Markup Language.
XHTML – Extensible Hypertext Markup Language extends HTML code to make it XML compliant. The W3C wants XHTML to replace HTML as the standard scripting language
STORED PROCEDURES
As mentioned previously – we can create stored procedures that are stored on the database server and can be used as needed. Some of the advantages of these stored procedures are:
BENEFITS OF THREE-TIERED APPLICATIONS