"It certainly can't be my fault"
I guess I'm being a little fussy, but one thing that is really starting to get old is people in newsgroups that bitch about technological limitations of things that they don't understand. Recently I read a post in a .NEt group where a guy pretty much lights into ADO.NET as pure hype. The post starts out:
<<After plowing through the pages and pages of fancy disconnected
relational blah blah, I find myself wanting to do something so simple
- that you wouldn't think twice about it in SQL. But in ADO.NET it
appears to be impossible - without resorting to hand coding all of it.
The more things change, the more they stay the same.>>
So from the sounds of this, you would think that this post has to do with a limitation in ADO.NET right? Well, shortly after the complaints we find out what his real problem is:
<<I have setup a Typed Dataset complete with relations, foreign keys and
all that jazz.
I have a GUI upon which is places two databound controls. When the
user selects a Security, I would like to display the list of availible
Exchanges for that Security.
So far, I don't see one good way of utilizing the relations in place
for doing that.
DataTable.Select does what? Return an array of DataRow. What the
hell can I do with an array of DataRow in regards to a databound
DataView.RowFilter takes a string expression that appears to allow a
relation to a Child - BUT ONLY if that child represents a single value
- otherwise you have to use an aggregate function - what the hell good is that.
FROM Exchange, Security, ExchSec
WHERE Exchange.ExchId = ExchSec.ExchId
AND Security.SecId = ExchSec.SecId
AND Security.SecId = "3"
Now, I'm not parsing words here, really, but what in the hell does this have to do with ADO.NET? How is any of this possible a shortcoming of the DataSet he's using or the disconnected model? If anything this is a shortcoming in DataBinding, not in ADO.NET. Implementing the exact same scenario under old school ADO 2.x would somehow be easier? The fact you can write a SQL Query to do this 'easily' means absolutely nothing. (And back when i was in 101 - that exact query would have gotten me a good lecture from good old Dr. Jarman - but that's a whole different issue).
What I'm saying in a roundabout way is that they guy has a legitimate issue here. Binding many-to-many relationships isn't all that fun but it's certainly doable. But what baseline is he comparing ADO.NET to? SQL? The Grid in Query Analzyer or Sql Plus? Although they all display data they are certainly used in different regards. But what bugs me is hearing people say somethign sucks or is lame just because they don't understand it. I've heard at least 200 of these types of comments about ADO.NET, and probably 3 times that for the Compact Framework. “Hey, you mean the Compact Framework doesn't support Remoting? What kind of lame a33 crap is it anyway?“ People have every right in the world to state such opinions but it gets a little annoying - at least withhold judgement until you know what you're talking about. Now every time I say this someone says something like “Well, do you have to have sex with a man to know that you're straight? Do you have to shoot up heroin to know it's bad for you? Do you have to actually sit next to Michael Moore to know that he smells like a33?“ To all of which I say No, no and no. However knowing that you're straight isn't the same as saying that being Gay sucks [probably a bad choice of words]. You can just take one look at Courtney Love and know Heroin is bad for you and hell, you can almost smell the sweat and sausage burps coming from Micheal Moore just watching him on TV.
Like any other technology, there's plenty to complain about in ADO.NET (although there's a lot less to complain about than any other data access technology I know), the Compact Framework, Fill In the Blank________________. But running around bitching about something just because you haven't learned it yet (NOTE: lots of things are a little difficult when you're first learning them - that's why they call it a learning curve) , especially bitching about stuff that you're factually incorrect on, serves no purpose whatsoever, other than giving insomniatic bloggers something to do when Coast To Coast AM doesn't have anything good on.
“Maybe the reason it 'sucks' so bad is because I'm using it incorrectly? Nah, it COULDN'T Be my fault” And <gasp>, although I answered the dudes question and asked a few follow up questions so I could help him out a little more, still no reply yet.