|
-
Jul 30th, 2008, 10:53 AM
#1
Thread Starter
Lively Member
[CLOSED] Can you perform a select query against the Dataset?
I have 2 tables in my dataset and want to create a select statement against the two tables with a join, creating yet a third table in my dataset. The key here, I want to do it AGAINST the cached Dataset and NOT the server.
I want the user to play with the numbers and see the results on the screen and when they're happy THEN they click save and the data goes to the server. I know how to do this in a function that loops record by record I was hoping I could just do a select on the two tables in the dataset and storing the results in a third. Can you do a select & join against a Dataset?
Thanks
Last edited by Venus; Jul 30th, 2008 at 04:14 PM.
-
Jul 30th, 2008, 11:03 AM
#2
Re: Can you perform a select query against the Dataset?
you should look for DataRelation object
__________________
Rate the posts that helped you 
-
Jul 30th, 2008, 11:12 AM
#3
Re: Can you perform a select query against the Dataset?
A datatable within a dataset has a select method. Could you use that?
E.g.
MyDataSet.MyDataTable.Select(field=value)
Last edited by FunkyDexter; Jul 30th, 2008 at 11:18 AM.
The best argument against democracy is a five minute conversation with the average voter - Winston Churchill
Hadoop actually sounds more like the way they greet each other in Yorkshire - Inferrd
-
Jul 30th, 2008, 04:11 PM
#4
Thread Starter
Lively Member
Re: Can you perform a select query against the Dataset?
The relation object I don't believe is something I can use I have a many to many relationship (child to child) I want to display in the same datagridview, one of the columns is calculated. It's really easy to do in SQL against server databases but I don't know how I'd do it against a cached Dataset instead with the two individual tables loaded seperately in that dataset I'd like to add a third table that joins them. I've researched it long enough, a Dataset isn't a Database you can filter & use expression columns but far as I can see you can't run a simple select statement against a dataset trying to "join" two seperate tables, you have to create the joined table manually.
Thanks!
Last edited by Venus; Jul 30th, 2008 at 04:26 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|