• Home
  • Jobs
  • Courses
  • Certifications
  • Companies
  • Online IDE
  • Login
  • Signup
MYTAT
  • Home
  • Jobs
  • Courses
  • Certifications
  • Companies
  • Online IDE
  • Login
  • Signup
ASP And ASP.NET Tutorials
  • ASP.NET Web Pages - Tutorial
  • ASP.NET Web Pages - Adding Razor Code
  • ASP.NET Web Pages - Page Layout
  • ASP.NET Web Pages - Folders
  • ASP.NET Web Pages - Global Pages
  • ASP.NET Web Pages - HTML Forms
  • ASP.NET Web Pages - Objects
  • ASP.NET Web Pages - Files
  • ASP.NET Web Pages - Databases
  • ASP.NET Web Pages - Helpers
  • ASP.NET Web Pages - The WebGrid Helper
  • ASP.NET Web Pages - The Chart Helper
  • ASP.NET Web Pages - The WebMail Helper
  • ASP.NET Web Pages - WebSecurity Object
  • ASP.NET Web Pages - Publishing The Website
  • ASP.NET Web Pages - Classes
  • ASP.NET Razor - Markup
  • ASP.NET Razor - C# And VB Code Syntax
  • ASP.NET Razor - C# Variables
  • ASP.NET Razor - C# Loops And Arrays
  • ASP.NET Razor - C# Logic Conditions
  • ASP.NET Razor - VB Variables
  • ASP.NET Razor - VB Loops And Arrays
  • ASP.NET Razor - VB Logic Conditions
  • ASP Tutorial
  • ASP Syntax
  • ASP Variables
  • ASP Procedures
  • VBScript Conditional Statements
  • VBScript Looping
  • ASP Forms And User Input
  • ASP Cookies
  • ASP Session Object
  • ASP Application Object
  • ASP Including Files
  • ASP The Global.asa File
  • ASP AJAX
  • ASP Sending E-mail With CDOSYS
  • VBScript Functions
  • VBScript Keywords
  • ASP Response Object
  • ASP Application Object
  • ASP Session Object
  • ASP Server Object
  • ASP ASPError Object
  • ASP FileSystemObject Object
  • ASP TextStream Object
  • ASP Drive Object
  • ASP File Object
  • ASP Folder Object
  • ASP Dictionary Object
  • ASP AdRotator Component
  • ASP Browser Capabilities Component
  • ASP Content Linking Component
  • ASP Content Rotator Component (ASP 3.0)
  • ASP Quick Reference
  • ADO Introduction
  • ADO Database Connection
  • ADO Recordset
  • ADO Display
  • ADO Queries
  • ADO Sort
  • ADO Add Records
  • ADO Update Records
  • ADO Delete Records
  • ADO Demonstration
  • ADO Speed Up With GetString()
  • ADO Command Object
  • ADO Connection Object
  • ADO Error Object
  • ADO Field Object
  • ADO Parameter Object
  • ADO Property Object
  • ADO Record Object
  • ADO Recordset Object
  • ADO Stream Object
  • ADO Data Types
  • Home
  • Courses
  • ASP And ASP.NET Tutorials
  • ADO Recordset

ADO Recordset

Previous Next

Create An ADO Table Recordset

To be able to read database data, the data must first be loaded into a recordset. 
 

After an ADO Database Connection has been created, as demonstrated in the previous chapter, it is possible to create an ADO Recordset.  

Suppose we have a database named "Northwind", we can get access to the "Customers" table inside the database with the following lines:

<%
set conn=Server.CreateObject("ADODB.Connection")
conn.Provider="Microsoft.Jet.OLEDB.4.0"
conn.Open "c:/webdata/northwind.mdb"

set rs=Server.CreateObject("ADODB.recordset")
rs.Open "Customers", conn
%>



Practice Excercise Practice now

Create An ADO SQL Recordset

We can also get access to the data in the "Customers" table using SQL:

<%
set conn=Server.CreateObject("ADODB.Connection")
conn.Provider="Microsoft.Jet.OLEDB.4.0"
conn.Open "c:/webdata/northwind.mdb"

set rs=Server.CreateObject("ADODB.recordset")
rs.Open "Select * from Customers", conn
%>



Practice Excercise Practice now

Extract Data From The Recordset

After a recordset is opened, we can extract data from recordset.  

Suppose we have a database named "Northwind", we can get access to the "Customers" table inside the database with the following lines:

<%
set conn=Server.CreateObject("ADODB.Connection")
conn.Provider="Microsoft.Jet.OLEDB.4.0"
conn.Open "c:/webdata/northwind.mdb"

set rs=Server.CreateObject("ADODB.recordset")
rs.Open "Select * from Customers", conn

for each x in rs.fields
  response.write(x.name)
  response.write(" = ")
  response.write(x.value)
next
%>



Practice Excercise Practice now

The ADO Recordset Object

The ADO Recordset object is used to hold a set of records from a database table. 



Practice Excercise Practice now

Previous Next
COMPANY
  • About us
  • Careers
  • Contact Us
  • In Press
  • People
  • Companies List
Products
  • Features
  • Coding Assessments
  • Psychometric Assessment
  • Aptitude Assessments
  • Tech/Functional Assessments
  • Video Assessment
  • Fluency Assessment
  • Campus
 
  • Learning
  • Campus Recruitment
  • Lateral Recruitment
  • Enterprise
  • Education
  • K 12
  • Government
OTHERS
  • Blog
  • Terms of Services
  • Privacy Policy
  • Refund Policy
  • Mart Category
Partner
  • Partner Login
  • Partner Signup

Copyright © RVR Innovations LLP 2025 | All rights reserved - Mytat.co is the venture of RVR Innovations LLP