.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
MarieAdela
Imran Ghani
Post New Web Links

ADO.NET: Building a Custom Data Provider for Use with the .NET Data Access Framework

Posted By:      Posted Date: August 21, 2010    Points: 0   Category :ASP.Net
 

The System.Data.dll assembly in the .NET Framework contains namespaces whose base classes can be used to create custom data providers. These namespaces also define a number of data access interfaces and base classes that let developers create data providers that will interoperate with other custom providers. Using the ADO.NET classes Connection, Command, DataReader, and DataAdapter, writing a provider is easier than writing one for OLE DB. This article explains these classes and their implementation, and how they can be used to write a variety of different kinds of data providers.

Bob Beauchemin

MSDN Magazine December 2001




View Complete Post


More Related Resource Links

Data Points: Deny Table Access to the Entity Framework Without Causing a Mutiny

  

Julie Lerman shows database administrators how to limit access to databases from the Entity Framework by allowing it to work only with views and stored procedures instead of tables-without impacting application code or alienating developers.

Julie Lerman

MSDN Magazine August 2010


Data Access: Building a Desktop To-Do Application with NHibernate

  

Building an NHibernate-based desktop application isn't any harder than building a web application, and in many cases NHibernate simplifies elements of session handling and concurrency.

Oren Eini

MSDN Magazine December 2009


SOA Data Access: Flexible Data Access With LINQ To SQL And The Entity Framework

  

Building a data access layer using LINQ to SQL and the ADO.NET Entity Framework allows you to decouple your application from the persistence technology you're using.

Anthony Sneed

MSDN Magazine December 2008


Building a Custom Data Grid: Performing Ad Hoc Web Reporting with a VBScript 5.0 Class Object

  

A flexible, customizable grid for displaying data is a useful tool for ASP developers. It allows Web visitors to customize their view of your data. This article takes the data grid presented in "Ad Hoc Web Reporting with ADO 2.0" by John Papa and Charles Caison (MIND, December 1998) and adds handy features such as a finds feature that supports multiple finds and a mode for adding and editing records. This version also improves response time by allowing asynchronous record download and it componentizes the code so it can be used as a standalone VBScript class object that can be reused in other pages.

Randall Kindig

MSDN Magazine July 2000


System.InvalidOperationException: Internal .Net Framework Data Provider error 12.

  

Hi,

I have created an application in which there are few forms. Each form has fields which are linked to a backend table/tables. My application is supposed to be accessed by multiple users concurrently. I ran a test where I created a class file in windows application and i ran a for loop in it to call the url of my application. I wanted to test the effect of firing around 200 queries to my query engine.

The test code is :

namespace MachineGun

{

static class Program

{

/// <summary>

/// The main entry point for the application.

/// </summary>

[STAThread]

Failed to find or load the registered .Net Framework Data Provider.

  

<p>

Hi,

I am using enterprise library 5.0,vs.net 2008,oracle 9i,odp.net 9.2.0.700 version.

In machine.config I added the line below in

<add name="Oracle Data Provider for .NET" invariant="Oracle.DataAccess.Client" description="Oracle Data Provider for .NET" type="Oracle.DataAccess.Client.OracleClientFactory , Oracle.DataAccess, Version=9.2.0.700, Culture=neutral, PublicKeyToken=89b483f429c47342"/>

 

DbProviderFactory pf = DbProviderFactories.GetFactory("Oracle.DataAcess.Client");

above line is throwing an error.

System.Configuration.ConfigurationErrorsException was unhandled by user code

Message="Failed to find or load the registered .Net Framework Data Provider."

Source="System.Data"

BareMessage="Failed to find or load the registered .Net Framework Data Provider."

Line=0

StackTrace:

at System.Data.Common.DbProviderFactories.GetFactory(DataRow providerRow)

at System.Data.Common.DbProviderFactories.GetFactory(String providerInvariantName)

at testweb2008.Classes.test..ctor(String strKey) in C:\Documents and Settings\Administrator\My Documents\Visual Studio 2008\Projects\testweb2008\testweb2008\Classes\test.cs:line 30

at testweb2008._Default.Page_Load(Object sender

Error: Failed to find or load the registered .Net Framework Data Provider.

  

Oracle 10
Windows 7
IIS 7.5
Page created with VS2010
ASP.NET v4.0

Hi,

When I created my website I downloaded the Oracle Database Access Component and the Oracle Tools for VS. Everything worked fine in development and running from the VS development server everything works perfect.

However when I deployed the site to IIS the site works fine until I attempt to open a page that has an oracle bound gridview in it. I then received the following error;

Failed to find or load the registered .Net Framework Data Provider.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Configuration.ConfigurationErrorsException: Failed to find or load the registered .Net Framework Data Provider.

[ConfigurationErrorsException: Failed to find or load the registered .Net Framework Data Provider.]
System.Data.Common.DbProviderFactories.GetFactory(DataRow providerRow) +2189034
System.Data.Common.DbProviderFactories.GetFactory(String providerInvariantName) +135
System.Web.UI.WebControls.SqlDataSource.GetDbProviderFactorySecure() +48
System.Web.UI.WebControls.SqlDataSource.Cr

SSIS with IBM OLE DB Provider for DB2 (SQL Command data access mode)

  

I have SSIS package which gets the data from DB2 servers, and I am using "IBM OLE DB driver for DB2" in source connection provider, which is mandatory to use in my case. And my data access mode is "Sql command". When I clicked on columns in OLE DB source , I am getting the following error message. But its working fine when i select data access mode as "Table\view". Please help me in this as soon as possible. Please look at the following error description.

*************************************************************************

Error at Data flow task [OLE DB SOurce]: An OLE DB error has occurred. Error code: 0x80040E21.

 (Microsoft Visual Studio)

===================================

Exception from HRESULT: 0xC0202009 (Microsoft.SqlServer.DTSPipelineWrap)

------------------------------
Program Location:

   at Microsoft.SqlServer.Dts.Pipeline.Wrapper.CManagedComponentWrapperClass.ReinitializeMetaData()
   at Microsoft.DataTransformationServices.DataFlowUI.DataFlowComponentUI.ReinitializeMetadata()
   at Microsoft.DataTransformationServices.DataFlowUI.DataFlowAdapterUI.connectionPage_SaveConnectionAttributes(Object sender, ConnectionAttributesEventArgs args)

 


Sateesh Maduri

MVC architecture in ASP.Net using C# and Microsoft Data Access Application block

  
The Model-View-Controller (MVC) pattern separates the modeling of the domain, the presentation, and the actions based on user input into three separate classes [Burbeck92]:

Model. The model manages the behavior and data of the application domain, responds to requests for information about its state (usually from the view), and responds to instructions to change state (usually from the controller).

View. The view manages the display of information.

Controller. The controller interprets the mouse and keyboard inputs from the user, informing the model and/or the view to change as appropriate.

ASP.NET 4.0 Dynamic Data and Many to Many Entity Framework Entities

  
I did not play much with Dynamic Data controls in VS2008 and just made a cool discovery in VS2010 Beta 2. This may not even be new, but as I'm sitting 30,000+ feet over the Atlantic ocean, I don't have access to VS2008 at the moment to check.

Need Oracle Data Provider .CS File for Oracle 10g Database connection !

  

Hi.,

I need a 'Wrapper.cs' file which takes care of the Database connection ( Oracle 10g) where

i can just call the method with my SQL Query

(eg)

Gridview1.DataSource = SampleWrapper.ExecuteDatatable("THE SQL QUERY");

Gridview1.DataBind();

Plz Post the link if there is any open source !    


Microsoft Application Block for Data Access in .NET

  

Hi all,

I was rummaging the internet learning aspx and came across the concept of: Microsoft Application Block for Data Access in .NET

It seems great of course. The articles are all early 2003-5 such as

http://www.codeproject.com/KB/database/MS_Application_Blocks.aspx

So the question is - is this tech still relevant and should I be using it?

Thanks,

Mat



data access library v4.1

  

Ive just started a project that will use the enterprise library 4.1 data access code blocks.  Its been years since ive used them, can anyone tell me what assemblies I need to reference in my project in order to use them ?  Ive referenced 


Microsoft.Practices.EnterpriseLibrary.Data


are there any others I need ?


Data accessors or Entity framework

  

The entlib 5 sugest me to use with data accessors for mapping data from database to my data objects (ORM).

But in .NET 3.5 and especially in .NET 4, I can use in entity framework as ORM methodology for data objects.

What data accessors uses advantages over the entity framework?

What differences that should be affect on my using decisions?


OData and AtomPub: Building an AtomPub Server Using WCF Data Services

  

Learn how to use the AtomPub protocol to pump up your blogs. Chris Sells includes a practical demonstration of mapping so you can expose a standard AtomPub service from a Web site and use Windows Live Writer to provide a rich editing experience against the service.

Chris Sells

MSDN Magazine August 2010


Practical OData: Building Rich Internet Apps with the Open Data Protocol

  

See how you can build Rich Internet Applications that take advantage of the OData protocol to creatively interact with Silverlight, PowerPivot, SQL Server, SharePoint, the Windows Azure platform, "Dallas" and more.

Shayne Burgess

MSDN Magazine June 2010


Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend