Languages

Fsharp
ActionScript
xBase
Clean
GPSS
PureBasic
Sieve
Erlang
JOVIAL
Mercury
Linda
DataFlex
PostScript
FoxPro2
VFP
Cobol
Prolog
Jython
Awk
VisualBasic
JavaScript
Matlab
ASP
Haskell
Csharp
D
Smalltalk
Nemerle
Pixilang
Java
SQL
Python
ObjectPascal
Ruby
Perl
Pascal
Assembler
PHP
C
Functions  Add function  Users  Exit  Profile  About  ASCII Table  Our helpers

ADO.NET


1 Datasets in Microsoft.Net

2 RecordSet Objects

3 Validating data in DataSet

4 Validation Properties of the DataColumn

5 The DataTable Object’s Constraints Collection

6 Creating Dataset at Design Time

7 Adding DataColumn Objects

8 New DataSet

Datasets in Microsoft.Net



Contributed by Raghav Nayak
(Page 1 of 8 )

ADO.NET was designed to meet the needs of a new programming model: disconnected data architecture, tight integration with XML, common data representation with the ability to combine data from multiple and varied data sources, and optimized facilities for interacting with a database, all native to the .NET Framework.The ADO.NET DataSet is a memory-resident representation of data that provides a consistent relational programming model regardless of the source of the data it contains.

A DataSet represents a complete set of data including the tables that contain, order, and constrain the data, as well as the relationships between the tables.The DataSet class and the classes contained in DataSet objects—DataTable, DataColumn, DataRow, Constraint, and DataRelation—reside in the System.Data namespace.

Features of DataSets

1 - Working with Disconnected Data

The data in DataSet is disconnected from database. Once you fetch the results of a query into a DataSet using a DataAdapter object, there is no longer a connection between DataSet and database. Changes you make to the contents of the DataSet will not affect the database. If other users modify data in the database that corresponds to the data in DataSet, you will not see those changes in your DataSet.

Working with disconnected data structures definitely has its benefits. The first major benefit of working with disconnected data is that it does not require a live connection to your database. Once you’ve fetched the results of your query into a DataSet object, you can close the connection to your database and continue to work with the data in your DataSet.

Disconnected data structures such as DataSets are also helpful when you build multi-tiered applications. If your application uses business objects running on a middle-tier server to access database, business object needs to pass disconnected data structures to client application. The DataSet object is designed for use in such situations. You can pass the contents of a DataSet from one component to another. The component that receives the data can work with the information as a DataSet (if the component is built using the Microsoft .NET Framework) or as an XML document.

2 - Scrolling, Sorting, Searching, and Filtering

The DataSet object lets you examine the contents of any row in your DataSet at any time. You can loop back and forth through the results of your query as often as you like. This makes the DataSet object ideal for scenarios in which your code needs to loop through data, such as in reporting routines. You can also easily build an application that allows a user to scroll back and forth through the results of a query.

DataSet objects also let you change the way you view the results of queries. You can sort the data in a DataSet based on a column or a series of columns. You can search for a row of data based on simple search criteria. You can also apply a filter to the data in your DataSet so that only rows that satisfy the desired criteria are visible.

3 - Working with Hierarchical Data

DataSet objects are designed to work with hierarchical data. The DataSet object lets you define relationships between the tables of data stored in the DataSet.

4 - Caching Changes

Working with read-only data is easy. One of the biggest challenges in building a database application is to transform the user’s input into changes to the contents of your database. Building such logic into a multi-tiered application can present an even greater challenge if your application needs to cache changes and submit them to your database all at once.

The DataSet object lets you cache changes to a row of data so that you can submit the changes to your database using a DataAdapter. You can also examine modified rows in your DataSet to determine how the row has changed (inserted, modified, or deleted) as well as to compare both the original and current values for each row.

5 - XML Integration

The ADO.NET DataSet was built from the ground up to work with XML. You can save and load the contents of a DataSet to and from files as XML documents. The DataSet also lets you separate the schema information (table, column, and constraint information) into an XML schema file.

In ADO.NET, DataSet objects and XML documents are almost interchangeable. It’s easy to move from one data structure to the other. This duality allows developers to use the interfaces they’re most comfortable with. XML programmers can work with DataSet objects as XML documents, and database programmers can work with XML documents as DataSet objects.

6 - Uniform Functionality

Developers who have worked with ADO might be aware that the Recordset object has features similar to those of the DataSet. The ADO Recordset object supports features such as filtering, searching, sorting, and caching updates. However, the manner in which you open a Recordset plays a large part in determining what functionality is available in the Recordset.


1 2 3 4 5 6 7 8
Distant Star's Sound Waves Reveal Cycle Similar to Sun

Illustration of the CoRoT satellite measuring the acoustic fluctuations of a star.

In a bid to unlock long-standing mysteries of the sun, including the impacts on Earth of its 11-year cycle, an international team of scientists has successfully probed a distant star.

By monitoring the star's sound waves, the team has observed a magnetic cycle analogous to the sun's solar cycle.

Results of the study, conducted by scientists at the U.S. National Center for Atmospheric Research (NCAR) in Boulder, Colo., and colleagues in France and Spain, are published this ...

More at http://www.nsf.gov/news/news_summ.jsp?cntn_id=117554&WT.mc_id=USNSF_51&WT.mc_ev=click


This is an NSF News item.

PycckaR
BepcuR


Articles
Articles


Library
Library


Downloads
Downloads

Google Chrome Golf 6
 © Internet, books, teachers and Rudevich Alexander brains.