why are .NET libraries focusing on query from database?
why are .NET libraries focusing on query from database?
DataTables.net is perfect, we all love it.
we love it as an UI tool, but database query is another concern.
many web application uses some orm tool for query data from database, and also data doesnt always come from db, maybe mock data for testing, or 3rd party webapi can provide.
i wish .net part would be a c# wrapper of DataTables.net's js api, it would be more and more effective imho
Replies
Hi,
The client-side doesn't really "care" what the backend is - you can readily consume any JSON data source with DataTables. It could come from the DataTables C# libraries, your own EF code, an ORM, Rails, a third party feed, a mock feed, whatever.
The .NET libraries I provide are designed to cover the most common use cases for CRUD interaction with a database. They don't cover all use cases, and trying to do so with them would be folly!
What data feed specifically are you thinking of that you'd like DataTables to work with?
Allan
I certainly appreciate your work; I wouldn't want to be misunderstood.
It’s just that, since work had already been done on the C# side for datatables.net, I thought a more general-purpose solution would have been better.
I have a new project using ASP.NET Core MVC and Clean Architecture, and the application will rely heavily on tables. The data models for the table columns are already defined on the C# side, and the app needs to support multiple languages. Instead of writing DataTables logic on the JS side for every screen—specifically re-defining columns—I was researching how to create a DataTables API wrapper using a generic builder pattern on the C# side (e.g., generating the JS config via methods like
ColumnFor(x => x.Name)based on data models). Just then, I came across DataTables.net version 3.0 and your work on the .NET side; seeing a structure tightly coupled to direct database queries made me wish there had been a more generalized implementation focused solely on generating the DataTables.net configuration.