Tuesday, January 17, 2012

JqGrid and DataTable comparision













jqGridDatatableDatatable (server side)
Data format JSON (returned by server) HTML(embedded in web page) JSON(returned by server)
SortingServer sideClient sideServer side
Paging Server side Client side Server side
Filtering/Search Server side
Supports both toolbar search and Custom search
Client side
Provides API for column search
Server side
Editing Supports both in-line editing and form editing (we can display the selected record in a pop-up for editing). Form editing not supported. In-line editing is supported by jEditable plugin. Form editing not supported. In-line editing is supported by jEditable plugin.
Add/Delete Built-in support jEditable and data tables editable plugins required.jEditable and data tables editable plugins required.
Performance Better performance with high volume of data. Not suited for high volume of data. Slows down with high volume of data.
Development Extensive Documentation and examples available Easy to use Relatively involves more client side scripting.
Asp.Net MVC Helper methods Both commercial and open source libraries available.

Open source library (Lib.Web.Mvc) on codeplex Library provides helper methods for different operations and creating grid control in the view.

It also allows to configure/format columns on the server side using data annotations e.g., we can define a javascript function for column rendering, which can display images, format strings, etc. and attach the formatter function to the column using attribute.

Server side validation can be implemented using data annotations.
Not available Not available

Knockout 2.0.0 released

Knockout 2.0.0 released

ConfigSource property in Web.Config file



configSource
You can use the configSource property of a ConfigurationSection to specify a separate file where the configuration of that section is stored.

Ex: All Connection strings are stored in a separate file "ConnectionStrings.config"



Content of ConnectionStrings.config



connectionString="Data Source=(local);Initial Catalog=Sample;Integrated Security=True;MultipleActiveResultSets=True"
providerName="System.Data.SqlClient" />

connectionString="metadata=res://*/MatsModel.csdl|res://*/SampleModel.ssdl|res://*/SampleModel.msl;provider=System.Data.SqlClient;provider connection string="Data Source=(local);Initial Catalog=Sample;Integrated Security=True;MultipleActiveResultSets=True;Application Name=EntityFramework""
providerName="System.Data.EntityClient" />


Benefits

  1. Using include files can result in a more logical and modular structure for configuration files.

  2. File-access security and permissions can be used to restrict access to sections of configuration settings.

  3. Settings in an include file that are not used during application initialization can be modified and reloaded without requiring an application restart.

ASP.NET MVC Execution Process

1. Request to an ASP.NET MVC application first pass through the UrlRoutingModel, which is a HTTP Module.
2. This model parses the request and performs route selection.
3. This UrlRoutingModel selects the first route object that matches the current request.
4. If no routes found, the UrlRoutingModel does nothing and fall back the request to ASP.NET or IIS.
5. From the Route object, it obtains IRouteHandler that is associated with the Route object. In MVC, the instance of IRouteHandler is MVCRouteHandler.
6. IRouteHandler creates an instance of IHttpHandler object and passes it to IHttpContext object. In MVC, The instance of IHttpHandler is MvcHandler.
7. The MVCHandler object then selects the appropriate controller that will ultimately handle the request.