Mike Borozdin's Blog

A blog about programming, web and IT in general

Follow Me

Search

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© 2013 Mike Borozdin

Put EntityDataSource Attributes to Code-Behind

The EntityDataSource control is a very powerful one. It allows you to rapidly create database driven application. You don’t have to manually write code for extracting, modification and deleting records from the database. Moreover since this code is backed by Entity Framework, you are not tied up with a particular database schema and can easily change it or even choose other database application.

However when working with EntityDataSource sometimes I feel like I using plain old SqlDataSource and simply have too much unnecessary code in my .aspx files. More...


Posted on Monday, March 23, 2009
Comments (2)

Free Entity Framework Learning Guide

I came across a wonderful learning guide for the Entity Framework that explains many essential and complex things about the Entity Framework, including:

  • Modeling Entities
  • Lazy Loading
  • Inheritance
  • Working with objects
  • Performance
  • Working with Stored Procedures

Moreover this 500 pages long learning guide is absolutely free and can be downloaded here with all examples.

http://weblogs.asp.net/zeeshanhirani/archive/2008/12/18/my-christmas-present-to-the-entity-framework-community.aspx


Posted on Monday, January 19, 2009
Comments (2)

Understanding Attaching/Detaching Objects in LINQ to SQL and in the Entity Framework

LINQ to SQL and the Entity Framework are very powerful tools, however as in many other useful tools there are some things you should be aware of when working with them. One of those things is object attaching and detaching. Let’s have a concrete example.

As you already know, you can retrieve an object from the database, update or remove it and all the necessary changes will be submitted to the database.

But what if you don’t want to perform additional SELECT query? Instead, you want just to perform one necessary query, either to update an object or remove it. More...


Posted on Thursday, January 15, 2009
Comments (2)

The List of the LINQ to SQL and Entity Framework Providers

If you are using Microsoft SQL Server you don’t experience any problems, SQL Server are supported by both LINQ to SQL and the Entity Framework. Frankly speaking, it couldn’t be otherwise, since they all are made by Microsoft.

However, if you are using a non-Microsoft database engine, it’s certainly worth knowing if you can use LINQ to SQL or the Entity Framework with it. Moreover, it’s always better if there is native support. More...


Posted on Tuesday, January 06, 2009
Comments (6)

Creating Entity Framework Driven ASP.NET Application

Introduction

I have already written several posts on the Entity Framework where I described the power of this particular ORM tool. I also mentioned the book on the Entity Framework written by a Microsoft MVP - Joydip Kanjila. This time I will publish an extract from the book that shows how you can build ASP.NET application by using the Entity Framework and the EntityDataSource control. It can also give a glimpse of the Entity Framework is, if you have no experience in it.

The tutorial covers the following topics:

  • Creating the Entity Data Model by using a graphical utility built-in Visual Studio 2008 SP1
  • Creating the Entity Data Model by using a command line utility
  • Using the EntityDataSource ASP.NET control
  • Displaying the data in a GridView

This tutorial uses a particular database, but in fact you can use any database you already have. More...


Posted on Saturday, January 03, 2009
Comments (3)

Learning Entity Framework

I suppose you have already heard about the Entity Framework, but probably didn’t have a chance to try it in action. So, you want to learn it. Of course, you can start with MSDN that is indeed is the num ber one resource .NET developers, you can also find a dozen of tutorials on the Net, but you know it’s always pleasant to have a paper book or perhaps its electronic versions that you can read everywhere, not only in front of your computer.

Entity Framework Tutorial So, I can recommend you a book More...


Posted on Thursday, December 25, 2008
Comments (1)

Data Manipulations with Entity Framework

When learning a new ORM one of the most important and interesting thing is to get to know how you can manipulate data with that tool.Thus, this particular thing is explained in this tutorial.

There are two ways of accessing data with the Entity Framework:

  • Entity SQL
  • LINQ to SQL

We will be using the latter in this tutorial. More...


Posted on Wednesday, October 01, 2008
Comments (0)

Getting Intrigued by Entity Framework

If you use LINQ to SQL, you may wonder why Microsoft released yet another ORM (Entity Framework), while they already had one. You may also be confused, because it’s not obvious which one to choose. Anyway, the Entity Framework has its own shiny features that don’t present in LINQ to SQL. Besides, you can still use LINQ to retrieve data with the Entity Framework, in this case, it’s called LINQ to Entities, at the same time you can also use a SQL like language – Entities SQL. In this story I’ll show one particular feature of Entity Framework that certainly must interest many developers.

Basicall y, Entity Framework provides a higher level of abstraction than LINQ to SQL. In fact, in hides the data level. So, you deal with objects that represent real entities, not database tables, like if you were using LINQ to SQL. I mean when you generate LINQ to SQL classes, it creates classes for each tables, even though those tables are merely junction tables without any reflection in our real life.

Let’s have a look at the example, to make things clear. More...


Posted on Sunday, September 28, 2008
Comments (2)

Entity Framework and MySQL

Although MySQL don't seem to be very interested in providing a native support for LINQ to MySQL and you have to use 3-rd party providers to interact with MySQL by using LINQ, they seem to move towards Entity Framework. They are holding a webinar about using Entity Framework with MySQL on September, 30.

I think this can be a one reason of many why it's worth using Entity Framework, the support by database vendors is a great thing. It is not the only reason, of course, there are many other ones. The main thing is that Entity Framework provides a higher level of abstraction than LINQ to SQL, for instance. It can be a topic for a series of articles, so I think, I'll cover Entity Framework in other articles.


Posted on Wednesday, September 10, 2008
Comments (1)