|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Populating typed datasets WITHOUT tableadaptersTyped datasets are great, but in one respect, the move to use table adapters
is a double edge sword. What I would like to be able to is to use the old fashion ds.tables() components to be able to iterate through each of the tables in the typed dataset and be able to fill them WITHOUT specifying each tableadapter . Is there an easy way to do this that I am missing? if I use the Load Method, I need to have a datareader and this means I need to get the selectcommand for each table. Are these accessible properties for each table? I am sure I am missing something obvious Thanks for your insight... Chris,
Because of the fact that the typed dataset is so different between 1.x, 2.0 Windowforms and 2.0 Aspnet, can you tell us if you use this in WindowForms or ASPNET? (The Load method makes it obvious that it is 2.0). However telling it in advance next time will make it easier to help you. Probably is than somebody more dedicated on that able to help you. Cor Show quote "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... > Typed datasets are great, but in one respect, the move to use table > adapters is a double edge sword. > > What I would like to be able to is to use the old fashion ds.tables() > components to be able to iterate through each of the tables in the typed > dataset and be able to fill them WITHOUT specifying each tableadapter . > > Is there an easy way to do this that I am missing? if I use the Load > Method, I need to have a datareader and this means I need to get the > selectcommand for each table. > Are these accessible properties for each table? > > I am sure I am missing something obvious > > > Thanks for your insight... > > > To your question on win forms/asp/ etc... neither... it was a generalized
question on ADO.. the data layer. not the client layer. I was drawn to use the type dataset because of the easy ability to drag and drop objects from the SQL database... with all that entails, but it looks like I am going to be encountering some of the issues with the N tier discussions on the board. What I want really to do is the following: 1) Be able to have a visual representation in VS ( like the typed dataset XSD) that graphically represents the DB objects (Big surprise) 2) Have the ability to add new objects to this representation via drag and drop methods (again check for typed datasets) 3) Have this representation automatically regenerate or modify itself because on changes on the database (or at least easily). If I add a column to the database, does it appear in the typed dataset automatically .This is currently done by typed datasets...more or less. The point is the key one: 4) Be able to AUTOMATICALLY populate a hierarchy of tables/entities based on their relations. It is quite easy to be able to determine the order of load based on relationships between objects in many situations, and I would have thought MSFT would have that ability by now :> So for example if I drop a parent table into a typed dataset with an FK to one of my other tables, you would think that it would automatically that this NEW table needs: a) a table adapters of the specifed type for the new table b) that it needs to be loaded BEFORE the table already in the DB. Instead that information is left to the programmer to do. Because of this, instead, I was looking at writing a generic routine that looks at all the tables and askews tableadapters. It will examine the tables and their relations and load the data in the order needed in order to avoid violating any dependent constraints. Miha's comments on a custom data adapter may be the best path. too bad this extremely common situation was not considered by MSFT in VS2005. Show quote "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message news:%23LaaAKoaGHA.4784@TK2MSFTNGP02.phx.gbl... > Chris, > > Because of the fact that the typed dataset is so different between 1.x, > 2.0 Windowforms and 2.0 Aspnet, can you tell us if you use this in > WindowForms or ASPNET? (The Load method makes it obvious that it is 2.0). > However telling it in advance next time will make it easier to help you. > > Probably is than somebody more dedicated on that able to help you. > > Cor > > "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht > news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... >> Typed datasets are great, but in one respect, the move to use table >> adapters is a double edge sword. >> >> What I would like to be able to is to use the old fashion ds.tables() >> components to be able to iterate through each of the tables in the typed >> dataset and be able to fill them WITHOUT specifying each tableadapter . >> >> Is there an easy way to do this that I am missing? if I use the Load >> Method, I need to have a datareader and this means I need to get the >> selectcommand for each table. >> Are these accessible properties for each table? >> >> I am sure I am missing something obvious >> >> >> Thanks for your insight... >> >> >> > > Chris,
But as long as you not tell in what VS there is no answer possible because as I already wrote the creating of strongly typed dataset is done in different ways depending on the version and type of use. It is as telling that you want to do something with your car. Cor Show quote "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht news:%23g3ZQIraGHA.996@TK2MSFTNGP04.phx.gbl... > To your question on win forms/asp/ etc... neither... it was a generalized > question on ADO.. the data layer. not the client layer. > > I was drawn to use the type dataset because of the easy ability to drag > and drop objects from the SQL database... with all that entails, but it > looks like I am going to be encountering some of the issues with the N > tier discussions on the board. > > What I want really to do is the following: > > 1) Be able to have a visual representation in VS ( like the typed dataset > XSD) that graphically represents the DB objects (Big surprise) > > 2) Have the ability to add new objects to this representation via drag > and drop methods (again check for typed datasets) > > 3) Have this representation automatically regenerate or modify itself > because on changes on the database (or at least easily). If I add a column > to the database, does it appear in the typed dataset automatically .This > is currently done by typed datasets...more or less. > > > The point is the key one: > > 4) Be able to AUTOMATICALLY populate a hierarchy of tables/entities based > on their relations. > It is quite easy to be able to determine the order of load based on > relationships between objects in many situations, and I would have thought > MSFT would have that ability by now :> > So for example if I drop a parent table into a typed dataset with an FK to > one of my other tables, you would think that it would automatically that > this NEW table needs: > > a) a table adapters of the specifed type for the new table > b) that it needs to be loaded BEFORE the table already in the DB. > > Instead that information is left to the programmer to do. > > Because of this, instead, I was looking at writing a generic routine that > looks at all the tables and askews tableadapters. It will examine the > tables and their relations and load the data in the order needed in order > to avoid violating any dependent constraints. > > > Miha's comments on a custom data adapter may be the best path. too bad > this extremely common situation was not considered by MSFT in VS2005. > > > > > > > > > "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message > news:%23LaaAKoaGHA.4784@TK2MSFTNGP02.phx.gbl... >> Chris, >> >> Because of the fact that the typed dataset is so different between 1.x, >> 2.0 Windowforms and 2.0 Aspnet, can you tell us if you use this in >> WindowForms or ASPNET? (The Load method makes it obvious that it is 2.0). >> However telling it in advance next time will make it easier to help you. >> >> Probably is than somebody more dedicated on that able to help you. >> >> Cor >> >> "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht >> news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... >>> Typed datasets are great, but in one respect, the move to use table >>> adapters is a double edge sword. >>> >>> What I would like to be able to is to use the old fashion ds.tables() >>> components to be able to iterate through each of the tables in the >>> typed dataset and be able to fill them WITHOUT specifying each >>> tableadapter . >>> >>> Is there an easy way to do this that I am missing? if I use the Load >>> Method, I need to have a datareader and this means I need to get the >>> selectcommand for each table. >>> Are these accessible properties for each table? >>> >>> I am sure I am missing something obvious >>> >>> >>> Thanks for your insight... >>> >>> >>> >> >> > > Ok... I must be missing something
I am building an IN MEMORY dataset... it will NOT be directly connected to a windows form, an ASP page or any other FRONT END item. It will read from a SQL database and right to a SQLdatabase. Where I come from this is a data access layer component. so please tell me (in detail) why the databinding (form/ASP,etc) are material? Show quote "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message news:OmOKqAsaGHA.4972@TK2MSFTNGP03.phx.gbl... > Chris, > > But as long as you not tell in what VS there is no answer possible because > as I already wrote the creating of strongly typed dataset is done in > different ways depending on the version and type of use. > > It is as telling that you want to do something with your car. > > Cor > > > "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht > news:%23g3ZQIraGHA.996@TK2MSFTNGP04.phx.gbl... >> To your question on win forms/asp/ etc... neither... it was a generalized >> question on ADO.. the data layer. not the client layer. >> >> I was drawn to use the type dataset because of the easy ability to drag >> and drop objects from the SQL database... with all that entails, but it >> looks like I am going to be encountering some of the issues with the N >> tier discussions on the board. >> >> What I want really to do is the following: >> >> 1) Be able to have a visual representation in VS ( like the typed >> dataset XSD) that graphically represents the DB objects (Big surprise) >> >> 2) Have the ability to add new objects to this representation via drag >> and drop methods (again check for typed datasets) >> >> 3) Have this representation automatically regenerate or modify itself >> because on changes on the database (or at least easily). If I add a >> column to the database, does it appear in the typed dataset automatically >> .This is currently done by typed datasets...more or less. >> >> >> The point is the key one: >> >> 4) Be able to AUTOMATICALLY populate a hierarchy of tables/entities based >> on their relations. >> It is quite easy to be able to determine the order of load based on >> relationships between objects in many situations, and I would have >> thought MSFT would have that ability by now :> >> So for example if I drop a parent table into a typed dataset with an FK >> to one of my other tables, you would think that it would automatically >> that this NEW table needs: >> >> a) a table adapters of the specifed type for the new table >> b) that it needs to be loaded BEFORE the table already in the DB. >> >> Instead that information is left to the programmer to do. >> >> Because of this, instead, I was looking at writing a generic routine that >> looks at all the tables and askews tableadapters. It will examine the >> tables and their relations and load the data in the order needed in order >> to avoid violating any dependent constraints. >> >> >> Miha's comments on a custom data adapter may be the best path. too bad >> this extremely common situation was not considered by MSFT in VS2005. >> >> >> >> >> >> >> >> >> "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message >> news:%23LaaAKoaGHA.4784@TK2MSFTNGP02.phx.gbl... >>> Chris, >>> >>> Because of the fact that the typed dataset is so different between 1.x, >>> 2.0 Windowforms and 2.0 Aspnet, can you tell us if you use this in >>> WindowForms or ASPNET? (The Load method makes it obvious that it is >>> 2.0). However telling it in advance next time will make it easier to >>> help you. >>> >>> Probably is than somebody more dedicated on that able to help you. >>> >>> Cor >>> >>> "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht >>> news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... >>>> Typed datasets are great, but in one respect, the move to use table >>>> adapters is a double edge sword. >>>> >>>> What I would like to be able to is to use the old fashion ds.tables() >>>> components to be able to iterate through each of the tables in the >>>> typed dataset and be able to fill them WITHOUT specifying each >>>> tableadapter . >>>> >>>> Is there an easy way to do this that I am missing? if I use the Load >>>> Method, I need to have a datareader and this means I need to get the >>>> selectcommand for each table. >>>> Are these accessible properties for each table? >>>> >>>> I am sure I am missing something obvious >>>> >>>> >>>> Thanks for your insight... >>>> >>>> >>>> >>> >>> >> >> > > as an addemndum to my eralier reply.. for the purpose of my application
consider this a Windows SERVICE No client at all.. does that help "what kind of something i want to do with my car"? Show quote "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message news:OmOKqAsaGHA.4972@TK2MSFTNGP03.phx.gbl... > Chris, > > But as long as you not tell in what VS there is no answer possible because > as I already wrote the creating of strongly typed dataset is done in > different ways depending on the version and type of use. > > It is as telling that you want to do something with your car. > > Cor > > > "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht > news:%23g3ZQIraGHA.996@TK2MSFTNGP04.phx.gbl... >> To your question on win forms/asp/ etc... neither... it was a generalized >> question on ADO.. the data layer. not the client layer. >> >> I was drawn to use the type dataset because of the easy ability to drag >> and drop objects from the SQL database... with all that entails, but it >> looks like I am going to be encountering some of the issues with the N >> tier discussions on the board. >> >> What I want really to do is the following: >> >> 1) Be able to have a visual representation in VS ( like the typed >> dataset XSD) that graphically represents the DB objects (Big surprise) >> >> 2) Have the ability to add new objects to this representation via drag >> and drop methods (again check for typed datasets) >> >> 3) Have this representation automatically regenerate or modify itself >> because on changes on the database (or at least easily). If I add a >> column to the database, does it appear in the typed dataset automatically >> .This is currently done by typed datasets...more or less. >> >> >> The point is the key one: >> >> 4) Be able to AUTOMATICALLY populate a hierarchy of tables/entities based >> on their relations. >> It is quite easy to be able to determine the order of load based on >> relationships between objects in many situations, and I would have >> thought MSFT would have that ability by now :> >> So for example if I drop a parent table into a typed dataset with an FK >> to one of my other tables, you would think that it would automatically >> that this NEW table needs: >> >> a) a table adapters of the specifed type for the new table >> b) that it needs to be loaded BEFORE the table already in the DB. >> >> Instead that information is left to the programmer to do. >> >> Because of this, instead, I was looking at writing a generic routine that >> looks at all the tables and askews tableadapters. It will examine the >> tables and their relations and load the data in the order needed in order >> to avoid violating any dependent constraints. >> >> >> Miha's comments on a custom data adapter may be the best path. too bad >> this extremely common situation was not considered by MSFT in VS2005. >> >> >> >> >> >> >> >> >> "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message >> news:%23LaaAKoaGHA.4784@TK2MSFTNGP02.phx.gbl... >>> Chris, >>> >>> Because of the fact that the typed dataset is so different between 1.x, >>> 2.0 Windowforms and 2.0 Aspnet, can you tell us if you use this in >>> WindowForms or ASPNET? (The Load method makes it obvious that it is >>> 2.0). However telling it in advance next time will make it easier to >>> help you. >>> >>> Probably is than somebody more dedicated on that able to help you. >>> >>> Cor >>> >>> "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht >>> news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... >>>> Typed datasets are great, but in one respect, the move to use table >>>> adapters is a double edge sword. >>>> >>>> What I would like to be able to is to use the old fashion ds.tables() >>>> components to be able to iterate through each of the tables in the >>>> typed dataset and be able to fill them WITHOUT specifying each >>>> tableadapter . >>>> >>>> Is there an easy way to do this that I am missing? if I use the Load >>>> Method, I need to have a datareader and this means I need to get the >>>> selectcommand for each table. >>>> Are these accessible properties for each table? >>>> >>>> I am sure I am missing something obvious >>>> >>>> >>>> Thanks for your insight... >>>> >>>> >>>> >>> >>> >> >> > > Chris,
Using other words, what are you using Version 2002/2003 Net 1.x Version 2005 Net 2.0 from which I understand now as it is Windowforms and not ASPNET. The designers from those build three different types of strongly typed datasets. Cor Show quote "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht news:uBIWDkwaGHA.4936@TK2MSFTNGP05.phx.gbl... > as an addemndum to my eralier reply.. for the purpose of my application > consider this a Windows SERVICE > No client at all.. does that help "what kind of something i want to do > with my car"? > > > "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message > news:OmOKqAsaGHA.4972@TK2MSFTNGP03.phx.gbl... >> Chris, >> >> But as long as you not tell in what VS there is no answer possible >> because as I already wrote the creating of strongly typed dataset is done >> in different ways depending on the version and type of use. >> >> It is as telling that you want to do something with your car. >> >> Cor >> >> >> "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht >> news:%23g3ZQIraGHA.996@TK2MSFTNGP04.phx.gbl... >>> To your question on win forms/asp/ etc... neither... it was a >>> generalized question on ADO.. the data layer. not the client layer. >>> >>> I was drawn to use the type dataset because of the easy ability to drag >>> and drop objects from the SQL database... with all that entails, but it >>> looks like I am going to be encountering some of the issues with the N >>> tier discussions on the board. >>> >>> What I want really to do is the following: >>> >>> 1) Be able to have a visual representation in VS ( like the typed >>> dataset XSD) that graphically represents the DB objects (Big surprise) >>> >>> 2) Have the ability to add new objects to this representation via drag >>> and drop methods (again check for typed datasets) >>> >>> 3) Have this representation automatically regenerate or modify itself >>> because on changes on the database (or at least easily). If I add a >>> column to the database, does it appear in the typed dataset >>> automatically .This is currently done by typed datasets...more or less. >>> >>> >>> The point is the key one: >>> >>> 4) Be able to AUTOMATICALLY populate a hierarchy of tables/entities >>> based on their relations. >>> It is quite easy to be able to determine the order of load based on >>> relationships between objects in many situations, and I would have >>> thought MSFT would have that ability by now :> >>> So for example if I drop a parent table into a typed dataset with an FK >>> to one of my other tables, you would think that it would automatically >>> that this NEW table needs: >>> >>> a) a table adapters of the specifed type for the new table >>> b) that it needs to be loaded BEFORE the table already in the DB. >>> >>> Instead that information is left to the programmer to do. >>> >>> Because of this, instead, I was looking at writing a generic routine >>> that looks at all the tables and askews tableadapters. It will examine >>> the tables and their relations and load the data in the order needed in >>> order to avoid violating any dependent constraints. >>> >>> >>> Miha's comments on a custom data adapter may be the best path. too bad >>> this extremely common situation was not considered by MSFT in VS2005. >>> >>> >>> >>> >>> >>> >>> >>> >>> "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message >>> news:%23LaaAKoaGHA.4784@TK2MSFTNGP02.phx.gbl... >>>> Chris, >>>> >>>> Because of the fact that the typed dataset is so different between 1.x, >>>> 2.0 Windowforms and 2.0 Aspnet, can you tell us if you use this in >>>> WindowForms or ASPNET? (The Load method makes it obvious that it is >>>> 2.0). However telling it in advance next time will make it easier to >>>> help you. >>>> >>>> Probably is than somebody more dedicated on that able to help you. >>>> >>>> Cor >>>> >>>> "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht >>>> news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... >>>>> Typed datasets are great, but in one respect, the move to use table >>>>> adapters is a double edge sword. >>>>> >>>>> What I would like to be able to is to use the old fashion ds.tables() >>>>> components to be able to iterate through each of the tables in the >>>>> typed dataset and be able to fill them WITHOUT specifying each >>>>> tableadapter . >>>>> >>>>> Is there an easy way to do this that I am missing? if I use the Load >>>>> Method, I need to have a datareader and this means I need to get the >>>>> selectcommand for each table. >>>>> Are these accessible properties for each table? >>>>> >>>>> I am sure I am missing something obvious >>>>> >>>>> >>>>> Thanks for your insight... >>>>> >>>>> >>>>> >>>> >>>> >>> >>> >> >> > > Ok...lets walk down the road a little further... I am aware that they are
strongly typed datasets... thats my point.. the use of tableadapters would have provided that information. I think that your terms are nto clear.. you obviously know I am using a .Net 2.0 frame work... so it really DOES NOT matter if it is ASP or windows... NOT AT ALL. In any case my original message was related to OVERRIDING the use of the strong typing by access properties within the table adapters to get the SELECTCOMMAND and access the the dataadapters. Again, I think miha comments on a custom adapter are the only way to go considering that MSFT did not build the typed dataset as well as I would have liked Show quote "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message news:eTPTL70aGHA.1020@TK2MSFTNGP02.phx.gbl... > Chris, > > Using other words, what are you using > > Version 2002/2003 Net 1.x > Version 2005 Net 2.0 from which I understand now as it is Windowforms and > not ASPNET. > > The designers from those build three different types of strongly typed > datasets. > > Cor > > "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht > news:uBIWDkwaGHA.4936@TK2MSFTNGP05.phx.gbl... >> as an addemndum to my eralier reply.. for the purpose of my application >> consider this a Windows SERVICE >> No client at all.. does that help "what kind of something i want to do >> with my car"? >> >> >> "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message >> news:OmOKqAsaGHA.4972@TK2MSFTNGP03.phx.gbl... >>> Chris, >>> >>> But as long as you not tell in what VS there is no answer possible >>> because as I already wrote the creating of strongly typed dataset is >>> done in different ways depending on the version and type of use. >>> >>> It is as telling that you want to do something with your car. >>> >>> Cor >>> >>> >>> "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht >>> news:%23g3ZQIraGHA.996@TK2MSFTNGP04.phx.gbl... >>>> To your question on win forms/asp/ etc... neither... it was a >>>> generalized question on ADO.. the data layer. not the client layer. >>>> >>>> I was drawn to use the type dataset because of the easy ability to drag >>>> and drop objects from the SQL database... with all that entails, but it >>>> looks like I am going to be encountering some of the issues with the N >>>> tier discussions on the board. >>>> >>>> What I want really to do is the following: >>>> >>>> 1) Be able to have a visual representation in VS ( like the typed >>>> dataset XSD) that graphically represents the DB objects (Big surprise) >>>> >>>> 2) Have the ability to add new objects to this representation via drag >>>> and drop methods (again check for typed datasets) >>>> >>>> 3) Have this representation automatically regenerate or modify itself >>>> because on changes on the database (or at least easily). If I add a >>>> column to the database, does it appear in the typed dataset >>>> automatically .This is currently done by typed datasets...more or less. >>>> >>>> >>>> The point is the key one: >>>> >>>> 4) Be able to AUTOMATICALLY populate a hierarchy of tables/entities >>>> based on their relations. >>>> It is quite easy to be able to determine the order of load based on >>>> relationships between objects in many situations, and I would have >>>> thought MSFT would have that ability by now :> >>>> So for example if I drop a parent table into a typed dataset with an FK >>>> to one of my other tables, you would think that it would automatically >>>> that this NEW table needs: >>>> >>>> a) a table adapters of the specifed type for the new table >>>> b) that it needs to be loaded BEFORE the table already in the DB. >>>> >>>> Instead that information is left to the programmer to do. >>>> >>>> Because of this, instead, I was looking at writing a generic routine >>>> that looks at all the tables and askews tableadapters. It will examine >>>> the tables and their relations and load the data in the order needed in >>>> order to avoid violating any dependent constraints. >>>> >>>> >>>> Miha's comments on a custom data adapter may be the best path. too bad >>>> this extremely common situation was not considered by MSFT in VS2005. >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message >>>> news:%23LaaAKoaGHA.4784@TK2MSFTNGP02.phx.gbl... >>>>> Chris, >>>>> >>>>> Because of the fact that the typed dataset is so different between >>>>> 1.x, 2.0 Windowforms and 2.0 Aspnet, can you tell us if you use this >>>>> in WindowForms or ASPNET? (The Load method makes it obvious that it is >>>>> 2.0). However telling it in advance next time will make it easier to >>>>> help you. >>>>> >>>>> Probably is than somebody more dedicated on that able to help you. >>>>> >>>>> Cor >>>>> >>>>> "Chris Smedley" <chris.smed***@terracomputing.com> schreef in bericht >>>>> news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... >>>>>> Typed datasets are great, but in one respect, the move to use table >>>>>> adapters is a double edge sword. >>>>>> >>>>>> What I would like to be able to is to use the old fashion ds.tables() >>>>>> components to be able to iterate through each of the tables in the >>>>>> typed dataset and be able to fill them WITHOUT specifying each >>>>>> tableadapter . >>>>>> >>>>>> Is there an easy way to do this that I am missing? if I use the Load >>>>>> Method, I need to have a datareader and this means I need to get the >>>>>> selectcommand for each table. >>>>>> Are these accessible properties for each table? >>>>>> >>>>>> I am sure I am missing something obvious >>>>>> >>>>>> >>>>>> Thanks for your insight... >>>>>> >>>>>> >>>>>> >>>>> >>>>> >>>> >>>> >>> >>> >> >> > >
Show quote
"Chris Smedley" <chris.smed***@terracomputing.com> wrote in message You mean the surrounding classes are not built well - yes, I agree - they news:%23k5LYc1aGHA.3444@TK2MSFTNGP05.phx.gbl... > Ok...lets walk down the road a little further... I am aware that they are > strongly typed datasets... thats my point.. the use of tableadapters would > have provided that information. > I think that your terms are nto clear.. you obviously know I am using a > .Net 2.0 frame work... so it really DOES NOT matter if it is ASP or > windows... NOT AT ALL. > > > In any case my original message was related to OVERRIDING the use of the > strong typing by access properties within the table adapters to get the > > SELECTCOMMAND and access the the dataadapters. > > Again, I think miha comments on a custom adapter are the only way to go > considering that MSFT did not build the typed dataset as well as I would > have liked are just for sample projects IMO. Your best bet is to avoid that stuff and use some sort of code generator or a library that helps you building dataadapters and similar classes. -- Miha Markic [MVP C#] RightHand .NET consulting & development www.rthand.com Blog: http://cs.rthand.com/blogs/blog_with_righthand/ I don't want to sound like a marketing guy but your point #4
(Automatically populate a hierarchy of tables based on their relations) is the exact same problem that I had. It was such a PITA, that I built a tool to do this for me, and now my company is selling it (free to try, and under $100 to buy). It's called the DataSet Toolkit, and it has a class called the MultiTableDataAdapter which does exactly the thing you want. Let me know what you think. http://www.hydrussoftware.com John B. http://johnsbraindump.blogspot.com You are free to define a custom DataAdapter and use it to fill or update
typed dataset or any typed table. Note that "typed" means just a layer on normal table. -- Show quoteMiha Markic [MVP C#] RightHand .NET consulting & development www.rthand.com Blog: http://cs.rthand.com/blogs/blog_with_righthand/ "Chris Smedley" <chris.smed***@terracomputing.com> wrote in message news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... > Typed datasets are great, but in one respect, the move to use table > adapters is a double edge sword. > > What I would like to be able to is to use the old fashion ds.tables() > components to be able to iterate through each of the tables in the typed > dataset and be able to fill them WITHOUT specifying each tableadapter . > > Is there an easy way to do this that I am missing? if I use the Load > Method, I need to have a datareader and this means I need to get the > selectcommand for each table. > Are these accessible properties for each table? > > I am sure I am missing something obvious > > > Thanks for your insight... > > > I'm wondering if it is possible to disable the generation of the
TableAdapter class in the .NET 2.0 DataSet? IMO is the DataSet class not the place to have the TableAdapter. I would use the DataSet class as a data definition - possibly in it's own assembly to be referenced by UI layer, DA layer etc. And the DA layer would be the correct place for the TableAdapter classes. Best regards, Benny Tordrup Show quote "Miha Markic [MVP C#]" <miha at rthand com> skrev i en meddelelse news:%23Y6oSoqaGHA.4340@TK2MSFTNGP03.phx.gbl... > You are free to define a custom DataAdapter and use it to fill or update > typed dataset or any typed table. > Note that "typed" means just a layer on normal table. > > -- > Miha Markic [MVP C#] > RightHand .NET consulting & development www.rthand.com > Blog: http://cs.rthand.com/blogs/blog_with_righthand/ > > "Chris Smedley" <chris.smed***@terracomputing.com> wrote in message > news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... >> Typed datasets are great, but in one respect, the move to use table >> adapters is a double edge sword. >> >> What I would like to be able to is to use the old fashion ds.tables() >> components to be able to iterate through each of the tables in the typed >> dataset and be able to fill them WITHOUT specifying each tableadapter . >> >> Is there an easy way to do this that I am missing? if I use the Load >> Method, I need to have a datareader and this means I need to get the >> selectcommand for each table. >> Are these accessible properties for each table? >> >> I am sure I am missing something obvious >> >> >> Thanks for your insight... >> >> >> > > I'm wondering if it is possible to disable the generation of the
TableAdapter class in the .NET 2.0 DataSet? IMO is the DataSet class not the place to have the TableAdapter. I would use the DataSet class as a data definition - possibly in it's own assembly to be referenced by UI layer, DA layer etc. And the DA layer would be the correct place for the TableAdapter classes. Best regards, Benny Tordrup Show quote "Miha Markic [MVP C#]" <miha at rthand com> skrev i en meddelelse news:%23Y6oSoqaGHA.4340@TK2MSFTNGP03.phx.gbl... > You are free to define a custom DataAdapter and use it to fill or update > typed dataset or any typed table. > Note that "typed" means just a layer on normal table. > > -- > Miha Markic [MVP C#] > RightHand .NET consulting & development www.rthand.com > Blog: http://cs.rthand.com/blogs/blog_with_righthand/ > > "Chris Smedley" <chris.smed***@terracomputing.com> wrote in message > news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... >> Typed datasets are great, but in one respect, the move to use table >> adapters is a double edge sword. >> >> What I would like to be able to is to use the old fashion ds.tables() >> components to be able to iterate through each of the tables in the typed >> dataset and be able to fill them WITHOUT specifying each tableadapter . >> >> Is there an easy way to do this that I am missing? if I use the Load >> Method, I need to have a datareader and this means I need to get the >> selectcommand for each table. >> Are these accessible properties for each table? >> >> I am sure I am missing something obvious >> >> >> Thanks for your insight... >> >> >> > > -- ---------------------------------------- Jeg beskyttes af den gratis SPAMfighter til privatbrugere. Den har indtil videre sparet mig for at få 2000 spam-mails. Betalende brugere får ikke denne besked i deres e-mails. Hent gratis SPAMfighter her: www.spamfighter.dk Hi Benny,
"Benny S. Tordrup" <nospam.bt.nospam@fk-data.nospam.dk> wrote in message Not sure but you can delete TableAdapter after they are created (I know, i news:O57DEX1bGHA.380@TK2MSFTNGP04.phx.gbl... > I'm wondering if it is possible to disable the generation of the > TableAdapter class in the .NET 2.0 DataSet? know). > So true, TableAdapters are like toys.> IMO is the DataSet class not the place to have the TableAdapter. I would > use the DataSet class as a data definition - possibly in it's own assembly > to be referenced by UI layer, DA layer etc. And the DA layer would be the > correct place for the TableAdapter classes. -- Show quoteMiha Markic [MVP C#] RightHand .NET consulting & development www.rthand.com Blog: http://cs.rthand.com/blogs/blog_with_righthand/ > > Best regards, > > Benny Tordrup > > "Miha Markic [MVP C#]" <miha at rthand com> skrev i en meddelelse > news:%23Y6oSoqaGHA.4340@TK2MSFTNGP03.phx.gbl... >> You are free to define a custom DataAdapter and use it to fill or update >> typed dataset or any typed table. >> Note that "typed" means just a layer on normal table. >> >> -- >> Miha Markic [MVP C#] >> RightHand .NET consulting & development www.rthand.com >> Blog: http://cs.rthand.com/blogs/blog_with_righthand/ >> >> "Chris Smedley" <chris.smed***@terracomputing.com> wrote in message >> news:uO34pmlaGHA.3328@TK2MSFTNGP02.phx.gbl... >>> Typed datasets are great, but in one respect, the move to use table >>> adapters is a double edge sword. >>> >>> What I would like to be able to is to use the old fashion ds.tables() >>> components to be able to iterate through each of the tables in the >>> typed dataset and be able to fill them WITHOUT specifying each >>> tableadapter . >>> >>> Is there an easy way to do this that I am missing? if I use the Load >>> Method, I need to have a datareader and this means I need to get the >>> selectcommand for each table. >>> Are these accessible properties for each table? >>> >>> I am sure I am missing something obvious >>> >>> >>> Thanks for your insight... >>> >>> >>> >> >> > > > > -- > ---------------------------------------- > Jeg beskyttes af den gratis SPAMfighter til privatbrugere. > Den har indtil videre sparet mig for at få 2000 spam-mails. > Betalende brugere får ikke denne besked i deres e-mails. > Hent gratis SPAMfighter her: www.spamfighter.dk > > Hi Miha,
"Miha Markic [MVP C#]" <miha at rthand com> skrev i en meddelelse That's exactly what I do.news:unxqkH2bGHA.628@TK2MSFTNGP04.phx.gbl... > > Not sure but you can delete TableAdapter after they are created (I know, i > know). And what i further like with Visual Studio 2005 is the partial class making it possible to enhance the dataset class without having enhancements deleted by the designer :-) Best regards, Benny Tordrup Hi Miha,
"Miha Markic [MVP C#]" <miha at rthand com> skrev i en meddelelse That's exactly what I do.news:unxqkH2bGHA.628@TK2MSFTNGP04.phx.gbl... > > Not sure but you can delete TableAdapter after they are created (I know, i > know). And what i further like with Visual Studio 2005 is the partial class making it possible to enhance the dataset class without having enhancements deleted by the designer :-) Best regards, Benny Tordrup -- ---------------------------------------- Jeg beskyttes af den gratis SPAMfighter til privatbrugere. Den har indtil videre sparet mig for at få 2014 spam-mails. Betalende brugere får ikke denne besked i deres e-mails. Hent gratis SPAMfighter her: www.spamfighter.dk |
|||||||||||||||||||||||