ADO & Recordsets. ADO Description & History  ActiveX Data Objects  History  1991 ODBC  Data Access Objects (DAO) for VB developers (JET)  Remote.

Slides:



Advertisements
Similar presentations
ADO DB in Access VBA © Walter Milner 2005 Slide: 1 ADO VBA Programming in Access.
Advertisements

1 Chapter 10 Protecting Data Integrity in a Multiuser Environment.
Database Processing Applications and Business Intelligence Chapter Seven DAVID M. KROENKE and DAVID J. AUER DATABASE CONCEPTS, 3 rd Edition.
Irwin/McGraw-Hill Copyright© 2000 by the McGraw-Hill Companies, Inc. PowerPoint® Presentation to accompany prepared by James T. Perry University of San.
CIS 338: Using ADO (ActiveX Data Objects) [largely replaced by adonet.vb] Dr. Ralph D. Westfall April, 2003.
Chapter 10 ADO. What is ADO? ADO is a Microsoft technology ADO stands for ActiveX Data Objects ADO is a programming interface to access data in a database.
Introduction to Database Processing with ADO.NET.
1 Chapter 12 Working With Access 2000 on the Internet.
Prentice Hall © COS 346 Day Agenda Capstone Progress report due Assignment 9 not corrected yet Assignment 10 posted (last one!!!) –Due.
The ADO Data Control. Universal Data Access Open Database Connectivity (ODBC) –standard for accessing data in databases OLE-DB –allows access to data.
ActiveX Data Object ISYS 562. ADO An ActiveX control ActiveX is build upon COM, a contract that defines a standard interface by which objects communicate.
Using Visual Basic 6.0 to Create Web-Based Database Applications
Using Objects and Properties
DAVID M. KROENKE’S DATABASE PROCESSING, 10th Edition © 2006 Pearson Prentice Hall COS 346 Day 23.
Programming the RecordSet Object
Visual Basic Database Access BICS546. Microsoft Universal Data Access OLE DB: The OLE database protocol –Allows a program to access information in any.
DAVID M. KROENKE’S DATABASE PROCESSING, 10th Edition © 2006 Pearson Prentice Hall 12-1 COS 346 Day 22.
CIS 451: ASP Recordsets Dr. Ralph D. Westfall May, 2002.
ASP.NET Programming with C# and SQL Server First Edition Chapter 8 Manipulating SQL Server Databases with ASP.NET.
Chapter 12 Database Connectivity with ASP.NET JavaScript, Third Edition.
ASP & ADO. Connection Object An implicit connection is created when we open a recordset without a connection object. –rs.open “Customer”, "DSN = Sales”
Objective In this session we will discuss about : What is ADO. NET ?
Overview of Database Access in.Net Josh Bowen CIS 764-FS2008.
© 1999, by Que Education and Training, Chapter 11, pages of Introduction to Computer Programming with Visual Basic 6: A Problem-Solving Approach.
Microsoft Access Ervin Ha.
ODBC Open DataBase Connectivity a standard database access method developed by Microsoft to access data from any application regardless of which database.
DAVID M. KROENKE’S DATABASE PROCESSING, 10th Edition © 2006 Pearson Prentice Hall 12-1 David M. Kroenke’s Chapter Twelve: ODBC, OLE DB, ADO, and ASP Part.
The Tip of the ADO-burg Francisco H Tapia. Ado Objects Command Connection Error Parameter Property Record RecordSet Stream.
Chapter 7 PHP Interacts with Ms. Access (Open DataBase Connectivity (ODBC))
ActiveX Data Object (ADO) in JavaScript J.L.Wang, Yen-Cheng Chen Dept. of Infomation Management Ming-Chuan University Jan
© 2006 ITT Educational Services Inc. Course Name: IT390 Business Database Administration Unit 9 Slide 1 IT 390 Business Database Administration Unit 9:
1 VBScript Session What we learn last session?
Introduction to ADO By David R. Stevenson Consulting Software Engineer ABB Automation.
Using Visual Basic 6.0 to Create Web-Based Database Applications
Databases and Data Access  Introduction to ADO.NET  ADO.NET objects  ADP.NET namespaces  Differences between ADO and ADO.NET.
Tutorial 10 by Sam ine1020 Introduction to Internet Engineering 1 Database & Server-side Scripting Tutorial 10.
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.
Universal Data Access and OLE DB. Customer Requirements for Data Access Technologies High-Performance access to data Reliability Vendor Commitment Broad.
Introduction to ADO Y.-H. Chen International College Ming-Chuan University Fall, 2004.
EM412 Using Adaptive Server Anywhere with Visual Basic Ali Chalhoub Technical Support Consultant iAnywhere Solutions
Lecture Note 10: Simple Database Techniques. Introduction –Database System –Access, SQL Server and others. –Microsoft Access - Interacting with this databases.
Visual Basic ADO Programming 56:150 Information System Design.
What is database?  Any Method for access info into Application from DataBase?  ODBC is standard for Accessing Data.  Problem with ODBC:  Information.
How to Connect to Database ODBC (Open Database Connectivity) ADO (ActiveX Data Object) ASP Code To Connect to Database Recordset Object Navigating through.
3-Tier Client/Server Internet Example. TIER 1 - User interface and navigation Labeled Tier 1 in the following graphic, this layer comprises the entire.
ActiveX Data Objects (ADO) is Microsoft’s latest database object model. The goal of ADO is to allow VB developers to use a standard set of objects to refer.
Chapter 9 Building the Shopping cart Objective Creating Shopping cart using session Variable. Creating a shopping cart using a database table. Use the.
Copyright © Curt Hill Connectivity Communicating with the Database.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
5-1 VISUAL J++ Colorado Technical University IT420 Tim Peterson.
Database Connectivity with ASP.NET. 2 Introduction Web pages commonly used to: –Gather information stored on a Web server database Most server-side scripting.
Introduction Because database applications today reside in a complicated environment, various standards have been developed for accessing database servers.
7-1 Active Server and ADO Colorado Technical University IT420 Tim Peterson.
1 ADO Activex Data Objects. 2 ADO ADO allows users to access data easily from many existing databases (such as Access or Paradox) From ODBC compliant.
Creating Simple and Parallel Data Loads With DTS.
Using databases ActiveX Data Objects (ADO) Connecting to a database Reading data from a database Inserting, updating and deleting records Using databases.
Lecture 4 Manipulating Form Data using methods of Recordset and RecordsetClone in VBA Restrict data with filter 1 Rapid Application Development.
 2 Data Object Library approaches ◦ DAO (Data Access Objects)  Original access strategy (up to VB6)  Closely linked to MS Access ◦ ADO (ActiveX Data.
ASP.NET Programming with C# and SQL Server First Edition
Visual Basic Database Access
Accessing the Database Server: ODBC, OLE DB, and ADO
آشنایی با نرم افزار Microsoft Access
Data Access Objects .
ADO VBA Programming in Access
ActiveX Data Objects (ADO)
INT213 Updating the Database.
ربط الفيجوال بيسك VB مع قواعد البيانات
VISUAL BASIC INTRODUCTION TO DATA CONNECTIVITY.
Chapter 10 ADO.
Unit – V Data Controls.
Presentation transcript:

ADO & Recordsets

ADO Description & History  ActiveX Data Objects  History  1991 ODBC  Data Access Objects (DAO) for VB developers (JET)  Remote Data Object (RDO) SQL, Oracle, etc (ODBC)  ODBCDirect utilizing RDO  OLE DB – ADO is a wrapper for OLE DB  High level, object oriented interface  Intended to replace DAO and RDO.

The ADO Object Model

The Connection Object  Represents link to the data source  Directly execute statements against source  Manage transactions  Expose events to notify of completed tasks  Provides Error object/collection  ADO does not require Connection object, but it is highly beneficial to declare explicitly.

The Recordset Object  Supports data paging  Disconnected recordsets  Filtering  Sorting  Storing multiple data sets in a single object

Recordsets and ASP VBScript  Creating a Connection object  Recordset samples  Executing action queries  Cursors  Locks

Connection Object  Microsoft Access Example  Microsoft SQL Server Example

Recordset Example 

Cursors  Determines how you can move through the recordset  Determines properties and methods made available through recordset object  Can only be specified upon opening a recordset  Specify it using.CursorType property in recordset object or as the third parameter using.Open method  Performance considerations

Cursors  Adopenforwardonly (Value 0) Default  The data is alive but you can only move forward.  Cannot move backward or to specific record  Adopenkeyset (Value 1)  The data is alive and any record read will be the most recent data.  Adopendynamic (Value 2)  The data is alive and additions will be noticed.  Accurate recordcount.  Adopenstatic (Value 3)  The data is dead. It is like a snapshot of the data.  Accurate recordcount.

Locks  Data modification and concurrency  Choice of locking depends on business rules

Locks  AdLockReadOnly (Value 1) Default  Read-only recordset, no locking provided since data cannot be updated.  AdLockPessimistic (Value 2)  Attempts to lock record once editing starts.  AdLockOptimistic (Value 3)  Only locks the record when.Update method is used.  AdLockBatchOptimistic (Value 4)  Locks are issued when.UpdateBatch method is used.