Okay, maybe this is just my “rookie” strongly typed dataset skills showing but why is it such a pain in the ass to map hiarchial schemas to datasets? I have this wonderful schema that I designed for the online donation site. I wanted to move data around from place to place using a dataset. (note: I am not trying to ignite the dataset vs. custom classes/ilist debate here). I chose datasets and that's that. However, when I got into trying to use xsd.exe to build the custom dataset wrapper class, it chokes on any nested complex type that has the same name.
Now the thing that drives me nuts is that it takes out the option of using user-defined complex types in the schema. For example, if you have a type that defines say an address block. If you keep the types simple in the block, life is good. However, if you add anything that makes the elements within the block complextypes you are screwed. I added an attribute of ID for the element so I can store something like the “City” and the “Id” that corresponds with that database value. Once you do that, the City element becomes a complexType and xsd.exe will map that to a DataTable and as everyone knows a dataset cannot have two DataTables with the same name. If you use the AddressType which defines City on another element that you want to be of type Address....Poof! It explodes.
Now, I know that I could write my own class generator. I really don't want to deal with doing that. I hardly have enough time in the schedule to use the restroom. I hope that they build on xsd.exe in 2005, and make it a little smarter when it comes to creating these classes.