Home All Groups Group Topic Archive Search About
Author
30 Mar 2005 11:59 PM
dmsy
Is there a way to join DataTables, kind of like how you do join in SQL?

Author
31 Mar 2005 12:34 AM
Elton Wang
If you mean join query, I suppose not.

Elton Wang


>-----Original Message-----
>Is there a way to join DataTables, kind of like how you
do join in SQL?
Show quote
>
>.
>
Author
31 Mar 2005 12:52 AM
Duwayne Sy
Thanks.

*** Sent via Developersdex http://www.developersdex.com ***
Author
31 Mar 2005 12:20 PM
oraclevsmicrosoft
There is not an exact equivalent of a SQL join, but you can use  the
dataRelation object. You may find it interesting if you want to do a
master/detail form.
In that case the dataSource for the detail control will not be a
dataTable but  the dataRelation object( for a  dataGrid object the
source will be the dataset and the member the datarelation  path, for
instance "mymastertable.myrelation") This will display only child 
records of the parent's table selected item.

For instance use this code to  create a dataRelation
dr= new DataRelation("Relation_Name", new DataColumn[] {
                        MyPrimarykeydataColumn}, new DataColumn[] {
                        myForeignkeydataColumn}, false);
            myDataSet.Relations.Add(dr);

hope this helps

Oracle Vs Microsoft

http://oraclevsmicrosoft.blogspot.com
Author
14 May 2005 4:41 PM
Adrian Moore
You might also want to check out this web-site that promises to provide a
..NET component to allow full SQL syntax queries against a DataSet.

http://queryadataset.com

Hope this helps
Ad.


Show quote
"dmsy" wrote:

> Is there a way to join DataTables, kind of like how you do join in SQL?
>
>

AddThis Social Bookmark Button