473,698 Members | 1,875 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

LINQ or DataSet?

Hi all,

Am I correct when stating that LINQ replaces somewhat DataTables?

I have done some reading concerning LINQ, but I'm still puzzled as to
whether I should use LINQ or not. My application imports data from an
XML file and stores the data in a DataSet (with 3 DataTables in it).
The DataTables are used to fill several DataGridViews (via DataViews/
BindingSources) . When the user saves his changes, the DataTables are
used to rebuild the xml file.

My data is stored hierarchical (via relations and constraints between
the DataTables), so suited for LINQ? Would it be an advantage in using
LINQ to perform this and leave the DataSet/DataTables behind? Will
performance gain? Sorry for maybe asking some stupid questions, but I
need to understand this LINQ thing before I move on with my
application.

Thanks in advance for your help,
Fre
Mar 7 '08 #1
1 2280
Frederik wrote:
Am I correct when stating that LINQ replaces somewhat DataTables?
LINQ for SQL contains an O/R mapper.

If you want an object oriented model in memory for your
data even though they are in an relational database
on disk then LINQ is one way to go (there are other
O/R mappers like NHibernate and LLBLGen).

If you want a relational model in memory then DataSet
is the way to go.

The bigger the project the more attractive the object oriented
model will be.

Arne
Mar 8 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
3596
by: =?Utf-8?B?V2lsc29uIEMuSy4gTmc=?= | last post by:
Hi Experts, I am doing a prototype of providing data access (read, write & search) through Web Service. We observed that the data storing in SQL Server 2005, the memory size is always within 250MB. Our aim is to support ~50K concurrency users. After investigation, we are thinking to use In-memory database for achieving
2
12595
by: =?Utf-8?B?VmFuZXNzYQ==?= | last post by:
I want to develop a datagridview allowing column selection and filtering, like this: http://www.codeproject.com/KB/grid/GridFilter.aspx This example is using dataset. My question is if: a) I use the same way, using dataset b) I use Linq converting a query to dataset c) or if would be done just with Linq
4
2157
by: cj | last post by:
Can I use LINQ in VB .Net 2008 to get to a Visual FoxPro Table? I've seen demos of it with SQL Server but they've used it with a server browser and I don't think that'd work when I need to see VFP tables.
4
29984
by: Lacutas | last post by:
Hi all, I am having some problems using LINQ to access Distinct records from a Dataset. I have looked around and believe it should be as simple as added .Distinct() to my LINQ query below, though intellisense doesn't even give that option! My DataSet has multiple tables, all populated with data. I have a table called DemographicCriteria which has the fields listed below. CriteriaID DemographicCode InputID
1
6986
by: Lacutas | last post by:
Hi I'm having some problems getting a dynamic LINQ query to work on my DataSet. The idea is that a user selects certain criteria, and then the LINQ query filters through the dataset making the requested changes. The table I am trying to alter is called RawData, this is defined in a DataSet but has no data columns as these aren't known until some data is imported. As part of my import routine it automatically creates the correct columns...
5
3817
by: Andy B | last post by:
I was just wondering, when you create dataContext methods, should you put business logic there to try and minimize pushing data through 2-3 layers of code? or should the business logic still go in another class somewhere making it access the dataContext methods?
2
2338
by: Andy B | last post by:
Hi... I have an sql server 2005 database that has a table called TestXml in it. The table has the columns ID (identity, int) and MyXml(xml). I created a stored proc on the server to insert a row into the table. It looks like this: create procedure InsertRow(@xmlDocument xml) as insert into TestXml values(@xmlDocument);
2
2376
by: =?Utf-8?B?anVsaW8=?= | last post by:
I am trying to use Update to save changes made on two DataGridView's to two tables (Posts & PostDetails) with a FK relationship. I say private void bUpdate_Click(object sender, EventArgs e) { try { CustomerDataSetTableAdapters.TableAdapterManager taManager = new CustomerDataSetTableAdapters.TableAdapterManager(); taManager.PostsTableAdapter = postsTableAdapter; taManager.PostDetailsTableAdapter = postDetailsTableAdapter;
1
1477
by: Sergey Topychkanov | last post by:
I have SQL SERVER 2008 Express and C# Express 2008 - both sp1. I can remove and update data in my database only thru direct SQL query thru database explorer, but quite unable to do it through dataset and linq. Thanks in advance Sergey
0
9152
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9014
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8855
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7708
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6515
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5857
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4358
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4612
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3037
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.