tags:

views:

129

answers:

3

If not which structure should I use ?

+1  A: 

DataSet can contain several datatables with different schemas. You can store your second datatable in a second table and reference it to your row at first table.

Also you can use WriteXml and ReadXml methods to store your datatable into a data cell.

Canavar
+1  A: 

Assuming you mean to persist it to a database, you would be better served looking at a foreign-key / DataRelation. If you really want more structured data in a cell, then perhaps something like xml, or some other serialization format.

Marc Gravell
+1 I agree - an XML document can be considered a "database".
DmitryK
(or use an auxiliary key-value table instead)
Robert Venables
+1  A: 

According to what I infer from your question you can say something like this :

DataRow dr = new DataRow();
DataTable dtable = dr[0].Table

MSDN : DataRow's DataTable Property : Gets the DataTable for which this row has a schema.

Example and Explanation : http://msdn.microsoft.com/en-us/library/system.data.datarow.table.aspx

Braveyard
I may be wrong, but I believe the OP is referring to *nested* data, rather than getting back to the table from a row.
Marc Gravell
That's what I know :) you can simply find the related information here : http://msdn.microsoft.com/en-us/library/system.data.datarow.table.aspx
Braveyard