COMP3241 E-Business Technologies Richard Henson University of Worcester October 2012.

Slides:



Advertisements
Similar presentations
Lecture plan Information retrieval (from week 11)
Advertisements

1 Chapter 12 Working With Access 2000 on the Internet.
15 Chapter 15 Web Database Development Database Systems: Design, Implementation, and Management, Fifth Edition, Rob and Coronel.
Introduction to ASP.NET. 2 © UW Business School, University of Washington 2004 Outline Static vs. Dynamic Web Pages.NET Framework Installing ASP.NET First.
Using Visual Basic 6.0 to Create Web-Based Database Applications
INTERNET DATABASE Chapter 9. u Basics of Internet, Web, HTTP, HTML, URLs. u Advantages and disadvantages of Web as a database platform. u Approaches for.
Introduction to Web Database Processing
Apache Tomcat Server Typical html Request/Response cycle
1 CS6320 – Why Servlets? L. Grewe 2 What is a Servlet? Servlets are Java programs that can be run dynamically from a Web Server Servlets are Java programs.
Chapter 9: The Client/Server Database Environment
Chapter 14 Database Connectivity and Web Technologies
Computer Science 101 Web Access to Databases Overview of Web Access to Databases.
Lecture The Client/Server Database Environment
2440: 141 Web Site Administration Web Server-Side Programming Professor: Enoch E. Damson.
The Client/Server Database Environment
Electronic Commerce Last Week
1 Web Database Processing. Web Database Applications Static Report Publishing a report is prepared from a database application and exported to HTML DB.
INTRODUCTION TO WEB DATABASE PROGRAMMING
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
COMP3121 E-Commerce Technologies Richard Henson University of Worcester October 2010.
CHAPTER 9 DATABASE MANAGEMENT © Prepared By: Razif Razali.
COMP2121 Internet Technology Richard Henson April 2011.
Database System Concepts and Architecture Lecture # 3 22 June 2012 National University of Computer and Emerging Sciences.
Beyond DHTML So far we have seen and used: CGI programs (using Perl ) and SSI on server side Java Script, VB Script, CSS and DOM on client side. For some.
Week 7 Lecture Web Database Development Samuel Conn, Asst. Professor
Chapter 16 The World Wide Web Chapter Goals Compare and contrast the Internet and the World Wide Web Describe general Web processing Describe several.
Server-side Scripting Powering the webs favourite services.
Interacting With Data Databases.
4-1 INTERNET DATABASE CONNECTOR Colorado Technical University IT420 Tim Peterson.
Basics of Web Databases With the advent of Web database technology, Web pages are no longer static, but dynamic with connection to a back-end database.
COMP3241 E-Commerce Technologies Richard Henson University of Worcester October 2012.
Server Side Programming ASP1 Server Side Programming Database Integration (cont.) Internet Systems Design.
COMP3121 E-Commerce Technologies Richard Henson University of Worcester November 2012.
Using Visual Basic 6.0 to Create Web-Based Database Applications
Internet, intranet, and multimedia database processing l Database processing across local and wide area networks l Alternative architectures for distributing.
COMP3121 E-Business Technologies Richard Henson University of Worcester October 2010.
COLD FUSION Deepak Sethi. What is it…. Cold fusion is a complete web application server mainly used for developing e-business applications. It allows.
Fundamentals of Database Chapter 7 Database Technologies.
M1G Introduction to Database Development 6. Building Applications.
9 Chapter Nine Compiled Web Server Programs. 9 Chapter Objectives Learn about Common Gateway Interface (CGI) Create CGI programs that generate dynamic.
Tutorial 10 by Sam ine1020 Introduction to Internet Engineering 1 Database & Server-side Scripting Tutorial 10.
COMP3121 E-Commerce Technologies Richard Henson University of Worcester November 2011.
COMP3241 E-Commerce Technologies Richard Henson University of Worcester October 2014.
COMP3121 E-Commerce Technologies Richard Henson University of Worcester October 2010.
File Processing Concepts – Field – combination of 1 or more characters that is the smallest unit of data to be accessed – Record – group of related fields.
COMP3241 E-Business Technologies Richard Henson University of Worcester October 2014.
Universal Data Access and OLE DB. Customer Requirements for Data Access Technologies High-Performance access to data Reliability Vendor Commitment Broad.
Relational Databases Database Driven Applications Retrieving Data Changing Data Analysing Data What is a DBMS An application that holds the data manages.
1 Welcome to CSC 301 Web Programming Charles Frank.
Mainframe (Host) - Communications - User Interface - Business Logic - DBMS - Operating System - Storage (DB Files) Terminal (Display/Keyboard) Terminal.
What is database?  Any Method for access info into Application from DataBase?  ODBC is standard for Accessing Data.  Problem with ODBC:  Information.
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 14 Database Connectivity and Web Technologies.
3-Tier Client/Server Internet Example. TIER 1 - User interface and navigation Labeled Tier 1 in the following graphic, this layer comprises the entire.
DB MidWare CSIS 4490 N-Tier Client/Server Dr. Hoganson Database Middleware Early client/server database systems –Two tier –Server does business logic (data.
COMP3121 E-Commerce Technologies Richard Henson University of Worcester November 2010.
COMP3241 E-Business Technologies Richard Henson University of Worcester October 2013.
COMP3241 E-Commerce Technologies Richard Henson University of Worcester November 2014.
ASP-2-1 SERVER AND CLIENT SIDE SCRITPING Colorado Technical University IT420 Tim Peterson.
COMP3241 E-Commerce Technologies Richard Henson University of Worcester December 2014.
E-commerce Architecture Ayşe Başar Bener. Client Server Architecture E-commerce is based on client/ server architecture –Client processes requesting service.
COMP3121 E-Commerce Technologies Richard Henson University of Worcester December 2009.
1 Chapter 1 INTRODUCTION TO WEB. 2 Objectives In this chapter, you will: Become familiar with the architecture of the World Wide Web Learn about communication.
Section 6.3 Server-side Scripting
Chapter 2 Database System Concepts and Architecture
The Client/Server Database Environment
COMP3241 E-Commerce Technologies
Lecture 1: Multi-tier Architecture Overview
Introduction of Week 11 Return assignment 9-1 Collect assignment 10-1
Chapter 10 ADO.
COMP3357 Managing Cyber Risk
Presentation transcript:

COMP3241 E-Business Technologies Richard Henson University of Worcester October 2012

Week 3 – Early Web Applications, ActiveX, and Database connectivity n Objectives:  Contrast between client-end applications and client-server applications  Explain the architecture of web-based database connection with server-scripting  Create a presentable shopping page using data from a database

Flatfiles and Databases n n Many so-called databases are just lists of data   retrieval of data can take a looonnnggg time n n Database proper links logically data:   hierarchically   relationally   object-oriented n n Relational still popular mainly because of SQL

Relational Databases n n Tight data structure means existing data can be more rapidly located… n n Real advantage of a true relational database is that SQL can be used for read/write & query database operations

relational Linking Server Script code with a relational database n n To make a two-way link with a relational database:   need relevant data access components » »components for IIS-based scripts available from Microsoft (MDAC)   “datasets” need to be defined using a programming language & embedded SQL   connectivity link needed to database pathname

Database Design n n Same principles apply as with any other relational database management system (RDBMS)…   identify entities & attributes   produce entity relationship » »define logic relationships between entities   make sure data is fully normalised » »create tables & links   use embedded SQL statements in the server script to communicate with the data: » »extract data from specific fields in particular tables » »put data into specific fields in particular tables n n Some “self-taught” developers are unaware of this, and try to build the data round the processing…

Evolution of Application - RDBMS connectivity n In the early web development days…  the connection of an application to a particular relational database would be hard coded and made available as an API (application program interface)  a client application then had to be written to use the proprietary API Even then, there was a problem: n If more than one RDBMS needed to be used?  several different APIs would be used  each needed a client application…  added greatly to the complexity of the task!

The Microsoft Solution: the ODBC API n Ideal: the “Universal Data Access” (UDA) model  all data consumers interact with all data providers…  response to the “API for each application” problem n First stage: ODBC = Open Database Connectivity  developed in early 1990s: »common API for writing applications to access ANY relational DBMS for which an ODBC driver had been written  Once the APIs had all been written, tried, and tested… »any relational database with an ODBC compliant interface could use them »easy database path connectivity string management

ActiveX n The next stage in evolution of Microsoft’s data objects model  sexy name for OLE v2.0  made up of… »OLE n Object Linking and Embedding… »Combined with COM n Common Object Model n ActiveX Data Objects make up a series of modular components called ADO  used for “run-time” web applications  basis of.net controls

What is ActiveX? What is ActiveX ® ? n V. successful Microsoft invention… n Run-time code became known as a “control”  NO source code so can’t be embedded in HTML, but can be called from a HTML file »Runs on any Browser (not interpreted…)  allows compiled (i.e. executable) code to talk to host applications  difficult to “hack” the code if source code not available n As the scripts are compiled into executable versions the source language is irrelevant  languages other than VB used…

More about VB ActiveX Data Objects (ADO) n Use a common, easy-to-use object model n Designed to simplify the writing of client applications to access data sources through OLE DB providers  more flexible than DSN »had to be specified on the local machine and limited to using the ODBC providers on that machine n Data sources could now also include:  spreadsheets  graphics  web pages…

OLE DB n Application of OLE/ActiveX principles to connectivity between applications and databases  to be more precise, relational database management systems! n Interface specification that provides a layer of abstraction between:  a data provider e.g. relational DBMS  a data consumer e.g. business object or client application

Universal Data Access in practice

System Connection to the Database n n Provided by Microsoft Data Access Components (MDAC)   easily downloaded: » » us/download/details.aspx?id=5793http:// us/download/details.aspx?id=5793   covers of range of databases   need most up-to-date version of MDAC (2.8 SP1) to work with latest database versions…

Use of MDAC with “path” n n Once the correct components have been chosen…   a logical 'connection' can be set up with the database – wherever it is!   If this isn’t correct, scripts on a web server can’t even link with, let alone interact with, a relational database n n “Database Path” must include:   a definition of where the database is   a few simple rules on how the database should be treated

Making a connection to a database on the web server n n Two systems still used:   ODBC – “legacy”.asp scripting   OLE DB –.aspx connectivity n n Whichever is used…   essential to get connectivity working correctly » »RAD tools like VWD very helpful in achieving this… n n Once connectivity achieved, server-script can use embedded SQL commands to link to and communicate smoothly with database tables   again… RAD tool like VWD can save a lot of time…

Databases & web pages n n Some early e-commerce applications used embedded JavaScript and a small local database n n Problems:   database took a long while to download & could be tampered with!   if database ran locally how could data be updated… prices changed, new products added?

Early online shopping example : n Came out of the early “wow, Java” revolution in web development  n Whole system (30kb) written in Java Script, runs on the client machine (!)  stores & presents product data  shows all the components and functionality expected of a shopping cart system  interfaces with merchant systems that can be used to handle online payment n TAKE A LOOK!!! Or download and run it yourself

Critical Look at Client-end “apps” n Absolutely fantastic! n Even better on a mobile… BUT usually for entertainment only… BUT usually for entertainment only…  only small data sources, or infrequently changed data sources are used  usually “single user”

Whatever happened to “client only” web shopping? n In an ideal (Internet) world everything would be able to run via the browser on the client machine. Result:  faster  all data local  more controlled n The “Java+client-end HTML” model is fine…  until you need to store and change data… securely!!

Applications requiring multi-client use & shared data n Specific requirement:  Large, regularly updated centralised data store that needs to be accessed by a number of clients  Requirements for client-end solution ? »database updated centrally »database downloaded every time the application is to be used!  Feasibility of client-end solution? »not powerful enough? »client not enough storage capacity? »not sufficient bandwidth? »downloading databases can compromise security

Using a remote database with a web page n n Compelling reason for client-server web applications…   data held in a secure place   product data easily updated   database processing can happen at a powerful server

Demands of Applications based on centralised data storage! n Typically… the database is :  secure  readily accessible from all clients  queried remotely  alterable only by specific persons n Only achievable through a client-server model

How Server Scripts can Interact with Databases n n Contain embedded SQL code that can extract data from or send data to a database

How Server Scripts can Interact with Databases   Whenever a database is updated… » »updated data picked up by server-script when it runs » »updated data displayed on client

How Server Scripts can Interact with Databases   Whenever a browser form captures data… » »data transferred directly to relevant server » »then stored in specified database field(s)

How Server Scripts Interact with Databases n n Whenever database information needs to be presented:   database fields and records taken into server memory   data sent to local machine to be displayed within a HTML format

Parameter Passing between Programs n n Essential to programming n n Coding can rapidly get quite complex… n n Essential for   product selection   passing data into a remote SQL query   sound horrendous? » »you’ll be eased into this gently… » »Starting NEXT week.

Mechanism for variable passing between Dynamic Web Pages n n HTML “GET” function:   parameter/s tagged on to the URL e.g. » »Get /thetest.jsp?firstname=richard&password=holidays&la stname=henson&action=transferbankfunds   Can result in v. long URLs…

Variable Passing between Dynamic Web Pages n n Alternative: “POST”   designed to be used within HTML forms… n n Example of syntax, added to HTML coding within …   post /thetest.jsp firstname=richard&password=holiday s&lastname=henson&action=transfer bankfunds

And now for the practical… Thanks for listening!   pnet-creating-shopping-cart-example.html pnet-creating-shopping-cart-example.html