College of Management: Iloilo City, Philippines
College of Management: Iloilo City, Philippines
ACCESS
can be used as either a database or an application development tool; key feature that sets it apart from other databases and tools is its ease of use; its simpler and straightforward.
Different types of ACCESS databases (as categorized by file extensions): 1) .MDB - extension of traditional ACESS database; - can contain data (in the form of tables and queries) and a front-end application (in the form of forms, reports and VBA code); - can contain links to other databases 2) .ADP - contains forms, reports, macros and VBA code modules. That data, however, is stored in an external database, e.g., SQL Server; - can also manipulate SQL server tables and stored procedures - similar with the first two. This type of database does not contain any editable source code. The application still works, but the code cannot be viewed or changed; - it cannot add or make changes to forms or reports.
3) .MDE or .ADE
A close relationship between ACCESS file types and the ways that ACCESS can be used. In general, ACCESS can be used in three major ways: 1. ACCESS can be used as a simple database. A single file (MDB) is created containing the database. Other tools, e.g., VB, Word, Excel, can be used as the interface to manipulate the ACCESS data. 2. ACCESS can be used just as a programming tool. The ACCESS application is contained inside a single file (ADP) and the database is located outside ACCESS. 3. ACCESS 2000 can be used both as a programming tool and a simple database. In this scenario, the database and the application may be contained in a single file (MDB), many files, or a file in combination with another external database. Database applications are a big part of development. Approximately 70 80% of applications built these days save their data to some type of database. Big enterprise applications typically use databases like SQL Server or Oracle. ACCESS deals with small desktop applications. ACCESS is a PC-based relational database. Some terms used when discussing a database: Database is simply a storage place for data; Has to use some form of logical construct to represent the data within a database (e.g., tables)
Relation or Table is a matrix of row/column intersections where each intersection contains a specific piece of data. Each column represents a specific characteristic of the main table.
BA 183.2 Notes
Relational database uses the concept of tables to organize the data in a database. Each table usually has some way to relate to other tables. Although the tables are completely independent of one another, they can easily connect data between tables. SQL or Structured Query Language; a powerful query language that can retrieve collections of related data from a relational database; uses a relatively easy syntax to retrieve data while hiding the underlying complex details of the retrieval process. Data integrity is the process of making sure the stored data is reliable and accurate. Using keys, table relationships, and field constraints are some ways of making sure the data has integrity.
Since ACCESS is a relational database, data is stored within tables as records (rows) and fields (columns). Data integrity is enforced by the table fields and by table relationships. Each field within a table must have a specific data type, may have certain key related constraints, or may have associated rules. These field level constraints make sure that: - the correct type of data is entered into a field - that a required field is not left blank - that there is no duplication of data within a column - that more complex rules are observed. This makes sure that no bad data is entered into a specific field. Relationships allow you to associate a column or columns in one table with a column or columns in another table. These relationships are used to make sure that data entered in one tables column has a corresponding record of data in another table. If there werent any associations, this would break the integrity of data. ACCESS can also create stored SQL queries. SQL statements can be used to retrieve, update or delete specific records that match a users needs. ACCESS can do more than store data and represent data with queries. Forms can be created to give a user-friendly face to the underlying data. Reports can be created to represent printable views of the data. Code modules can be used to create reusable sets of instructions for the ACCESS applications. ACCESS macros can be used as alternative to VBA code. Macros allow you to define a variety of actions to do specific tasks. Developing ACCESS Applications Applications are generally built to simplify a certain task or group of tasks. This task can be straightforward or complicated. Applications can consist of many different components. Generally, it consists of : 1. User interface used by the end-user to enter and view data 2. Database used to store and retrieve data 3. Components that manipulate the data Most ACCESS applications are built to give a user-friendly interface to data. Certain types of organizational needs fit ACCESS functionality better than others. These needs can be broken into the following categories: 1. Personal or Single User - application usually meant for a single person to enter data and produce results 2
BA 183.2 Notes
application usually straightforward, consisting of data-entry screens, a database and some reports key requirement of these systems are that they meet the functional requirements and perform well
2. Small business and Company department - typically more than one person that requires use of applications - on the average, used by 2-25 users and may have 5 simultaneous users accessing the application at one time - tend to have more functionality and require a certain level of security - scalability becomes an issue as the small business or department grows - have to be easily configurable, since more than one user maybe required to change the application - must have the ability to grow as the business requirements expand
3. Enterprise organizations - large organizations require the same type of application as small business and department requires except they have to be able to handle larger number of concurrent users. These applications may have 30 or more potential users, with 10 to 20 simultaneous users accessing the application. - Besides the items mentioned in #2, security and reliability of data become key issues - Generally, other environments like VB are more appropriate 4. Distributed organizations - are applications used over a company intranet or over the Internet - depending on the size of the organization, intranet applications may have hundreds of simultaneous users accessing an application - Internet applications include: o B2C you sell something to the public o B2B you sell something or share information with businesses ACCESS quickly and easily help build prototype applications, however, it is important to start off by doing an analysis of the end users needs. 1. You want to make sure that ACCESS will solve the needs of the end users. 2. You want to understand all of the different pieces of data that will be required by the application. Discovering all the different pieces of data that need to be captured or produced up front makes the process of application development much easier. Database design also is a key issue when developing applications. Database should be designed well. Testing in ACCESS involves making sure the application functions as intended, that the forms function as required, and that reports will generate correct data. In addition, the users will have to test that the application meets the needs of the business. When should ACCESS be used in application? When the aim involves gathering of data. (ACCESS is optimized for small applications that rely on database). 3
BA 183.2 Notes
Application Design Details - Development of ACCESS across network and user boundaries Concepts: Client-Server Applications began with influx of PCs on a network. A client-server model for an application is based on a modular and versatile infrastructure intended to improve scalability and interoperability The Client part of an application requests services and the server part provides services. A client-server application does not have to be more than one machine. The full application can be on a single machine. Generally, a client-server application is broken into three parts: Presentation graphical and visual elements Application logic business rules Data the data or database Categories of Applications: 1. Single-Tier Application - is an application where all the layer reside as one unit on one machine Typically, the presentation layer is mixed up with the application logic, and the application logic is mixed up with data layer. Advantage: relatively easy to build and initially deploy Disadvantage: maintainability is difficult and no data is shared across users 2. Two-Tier Application presentation layer is located on the client and the data is located on the server as a separate piece. The application logic layer maybe located on the server or on the client. When the application logic is on the client, logic is intermixed with the presentation code, and when the application logic is on the server, logic is handled by the database engine. [Note: Tiers are logical and not physical. Although a 2-tier application consists of a client part and a server part, the entire application may reside on the same machine, although commonly they will be located on separate machines.] Advantage: The separation of 2 tiers will allow sharing of data, consistency of data usage, and simplify report generation. Disadvantage: difficult to maintain (for example, if application logic is at the client, whenever a change is made to the application layer, this change will have to be made to all of the clients), and are still difficult to scale up since we normally have a limit on concurrent database connections.
BA 183.2 Notes
a. Two-Tier Fat Client if application logic is embedded in the presentation layer, we have what we term a fat (sometimes called thick or rich) client. The client will do most of the work while the server stores the data. Compared with the single-tier application, the two-tier fat client model, is still a fairly simple model to program. However, we are also now able to share the data with other users. b. Two-Tier Thin Client if application logic is located on the server, alternative type of two-tier client called a thin client. In this scenario, the business rules are stored as queries in the database. Advantage: increase maintainability because application logic resides in only one place : the server Disadvantage: puts more strain on the server 3. Three-Tier and n-Tier application is broken down into three separate parts: the presentation, application logic and data. VB or C++ usually used to create this application Advantage: can produce the most efficient, scalable and flexible application Disadvantage: the most complex application to build Cannot be used to create components that will reside on the business server May be used as presentation layer or the data layer in large applications, but not as pure application logic layer 4. Internet Application can be 2-, 3-, or n-tier application. In a 3- or n-tier environment, the different layers are located on the following different areas: presentation layer is a web page application logic layer is usually on the web server or on its own server the data is still located on the database server
Purposes of database design: 1. get rid of duplication of data within a database and maintain data integrity. Duplication of data wastes space, decrease performance, and can lead to many potential errors. 2. increase performance of a database. If database is designed well, it will perform well. 3. easily expand a database. Businesses are always expanding and being modified. Applications and databases have to be built so that they can be easily changed. 4. quickly create forms and reports using the ACCESS wizards. Administering screens can be quickly created using the built-in ACCESS wizards.
BA 183.2 Notes
Components of a Logical Database Design: 1. Entities simply a person, place, event or thing about which we intend to collect data. Entities are typically nouns that describe the different interacting items in an application. 2. Attributes a characteristic of an entity; can be either simple attributes or composite attributes. 3. Relationships describe how entities relate to and interact with one another. The ability to create (and later enforce) relationships allows developers to build some of the business functionality directly into the database. There are three main types of relationships that entities can have: a. one-to-one b. one-to-many c. many-to-many