Querying Information in a Database. CONTENTS Relational Database Systems Creating Database with SQL Server Reading Data with LINQ Requirements to Get.

Slides:



Advertisements
Similar presentations
ADO.Net Modelo para acesso a dados nas aplicação.Net Componentes: DataSet.Net Data providers: Connection Command DataReader DataAdapter.
Advertisements

By Chris Pascucci and FLF
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 ADO.NET. 2.NET Framework Data Namespaces System.Data –Base set of classes and interfaces for ADO.NET System.Data.Common –Classes shared by the.NET Data.
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.
Programming in ADO.NET: Data-Centric Applications and ADO.NET Original copyright by Microsoft, 2002, with minor modifications by Dan Eaves, 2005.
Objective In this session we will discuss about : What is ADO. NET ?
Overview of ADO.NET Chapter 1 ADO.NET 4.0 Development.
Overview of Database Access in.Net Josh Bowen CIS 764-FS2008.
CIS 764 – Presentation Somil Chandwani.  With Microsoft Data Access Components (MDAC), developers can connect to and use data from a wide variety of.
C# programming with database Basic guideline. First step Install SQL Server 2008/2010 (Professional edition if possible) Install Visual Studio 2008/2010.
ASP.NET Part 3 Instructor: Charles Moen CSCI/CINF 4230.
Overview of ADO.NET Whidbey  Wallace B. McClure  Scalable Development, Inc. Scalable Development, Inc. Building systems today that perform tomorrow.
ADO.NET – part II August 2004 [ Marmagna Desai]. CONTENTS ADO vs ADO.NET ADO.NET – Managed providers Connecting to Database SqlConnection Selecting Database.
ODBC, OLE DB, and ADO Introduction Dr. Ron Eaglin.
PHP Data Object (PDO) Khaled Al-Sham’aa. What is PDO? PDO is a PHP extension to formalise PHP's database connections by creating a uniform interface.
ADO.NET A2 Teacher Up skilling LECTURE 3. What’s to come today? ADO.NET What is ADO.NET? ADO.NET Objects SqlConnection SqlCommand SqlDataReader DataSet.
1 UCN Technology: Computer Science: Autumn 2012 ADO.NET 2.0 Architecture DataReader DataSet Connection factory Config file.
1 ASP.NET ASP.NET Rina Zviel-Girshin Lecture 4. 2 Overview Data Binding Data Providers Data Connection Data Manipulations.
Web Services Week 8 Aims: –Using web services as front ends to databases Objectives: –Review of relational databases –Connecting to and querying databases.
Accessing SQL Server and OLE DB from.NET Svetlin Nakov Telerik Corporation
A Simple Introduction. What is ADO.net? First the word ADO stands for ActiveX Data Objects And it is an integral part of.Net Framework of Microsoft hence.
Needs for Accessing Database To make your web site more dynamic and maintainable, you can display information on your web pages that are retrieved from.
Databases and Data Access  Introduction to ADO.NET  ADO.NET objects  ADP.NET namespaces  Differences between ADO and ADO.NET.
ADO.Net CS795. What is ADO.Net? Database language spoken by managed applications ADO.net database accesses go through modules: data providers –SQL Server.Net.
.NET Data Access and Manipulation ADO.NET. Overview What is ADO.NET? Disconnected vs. connected data access models ADO.NET Architecture ADO.NET Core Objects.
1 Introduction to ADO.NET Microsoft ADO.NET 2.0 Step by Step Rebecca M Riordan Microsoft Press, 2006.
Database, SQL, and ADO.NET- Part 1 Session 11 Mata kuliah: M0874 – Programming II Tahun: 2010.
Copyright 2008 Judith A Copeland - Accessing The Database By Judi Copeland.
Objectives In this lesson, you will learn to: *Identify the need for ADO.NET *Identify the features of ADO.NET *Identify the components of the ADO.NET.
ASP.NET Rina Zviel-Girshin Lecture 5
Module 9: Accessing Relational Data Using Microsoft Visual Studio.NET.
Session 8: ADO.NET. Overview Overview of ADO.NET What is ADO.NET? Using Namespaces The ADO.NET Object Model What is a DataSet? Accessing Data with ADO.NET.
Module 7: Accessing Data by Using ADO.NET
Christopher M. Pascucci.NET Programming: Databases & ADO.NET.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 Introduction to ADO.NET ADO.NET - Lesson 01  Training time: 10 minutes  Author:
Presented by Joseph J. Sarna Jr. JJS Systems, LLC
An Introduction to ADO.Net Marmagna Desai.NET Seminar, Fall-2003.
ADO.NET connections1 Connecting to SQL Server and Oracle.
1 Data Classes- DataView DataGridView Control. Objectives 2  Data Class  DataAdapter  DataReader  DataSet  DataTable  DataView  DataGridView Control.
Why ADO.NET Not your father’s Data Access.
PHP Workshop ‹#› PHP Data Object (PDO). PHP Workshop ‹#› What is PDO? PDO is a PHP extension to formalise PHP's database connections by creating a uniform.
PHP Workshop ‹#› أطلق إبداعك 2 أطلق إبداعك 2 مدرس معتمد من مركز زووم PHP Data Object (PDO)
Database Connectivity with ASP.NET. 2 Introduction Web pages commonly used to: –Gather information stored on a Web server database Most server-side scripting.
ADO.NET FUNDAMENTALS BEGINNING ASP.NET 3.5 IN C#.
Coding ADO.NET Objects: Connection, Command, DataReader.
Module 4 Introduction ADO.NET.
Active Data Objects Using.Net ADO.Net Farooq Ahmed Amna Umber Summayya Shehzad.
Module 5 Data Classes DataView – DataGridView Control 1.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 The SqlCommand Object ADO.NET - Lesson 03  Training time: 15 minutes  Author:
Data Access. ADO.NET ADO.NET is the primary library for building database solutions within the.NET Framework. ADO.NET does not replace ADO. ADO and OLEDB.
ADO .NET from. ADO .NET from “ADO .Net” Evolution/History of ADO.NET MICROSOFT .NET “ADO .Net” Evolution/History of ADO.NET History: Most applications.
.NET Data Access and Manipulation
C# 1 CSC 298 ADO.NET. C# 2 ADO.NET  A data access technology that maps very well to the world of the web (disconnected architecture)  data is retrieved.
ASP.NET Programming with C# and SQL Server First Edition
Data Access with ADO.NET
Introduction to ADO.NET
Introduction to Database Processing with ADO.NET
Introduction to Database Processing with ADO.NET
ADO.NET Framework.
How to Create Login Form using vb.net and SqlServer Database
Lecture 6 VB.Net SQL Server.
Overview of Data Access
Overview of Data Access
Tonga Institute of Higher Education
מתחברים למסד נתונים היכרות עם ADO.Net.
برنامه نویسی سیستم های شی گرا
Introduction to Database Programming through ADO. NET
Presentation transcript:

Querying Information in a Database

CONTENTS Relational Database Systems Creating Database with SQL Server Reading Data with LINQ Requirements to Get Data From Database Step by Step Writing Data to on DataBase Summary Examples Questions

Relational Database Systems Oracle FoxPro IBM DB2 Linter Microsoft Access Microsoft SQLServer MySQL PostgreSQL SQLite

Creating Database with MySQL

Reading Data with LINQ

Requirements to Get Data From Database Step by Step Adding Namespace Creating Connection and Opening it Determine the SqlDataAdapter Reading Data Closing Connection

Adding Namespace System.Data.SqlClient (the.NET Framework Data Provider for SQL Server) System.Data.Odbc (the.NET Framework Data Provider for ODBC) System.Data.OracleClient (the.NET Framework Data Provider for Oracle) System.Data.OleDb (the.NET Framework Data Provider for OLE DB)

Connection The Connection Object is a part of ADO.NET Data Provider and it is a unique session with the Data Source The Connection Object is Handling the part of physical communication between the C# application and the Data Source Opening connection is like opening a folder

Connection SqlConnection conn = new SqlConnection(); Con.ConnectionString Con.Open();

SqlDataAdapter A data adapter is an object used to exchange data between a data source and a data set

SqlDataAdapter

Reading Data and Closing Connection DataGridView displays data from SQL databases. This tutorial shows how to display a specific table from a database and display it on a DataGridView. This is done with a DataAdapter DataGridView.DataSource = DataTable; Conn.Close(); //Important to close connection

Writing Data to on DataBase Use SqlCommand Use ExecuteNonQuery string Kmt = "INSERT INTO Customers (CustomerID,CompanyName,ContactName,City) VALUES ('" + textBox1.Text + "','" + textBox2.Text + "', …) "; SqlCommand komut = new SqlCommand(Kmt, baglanti); komut.ExecuteNonQuery();