On this page.... RSS 2.0 | Atom 1.0 | CDF
# Tuesday, October 4, 2005

Looks like VB is growing up.  It finally has curly braces thanks to LINQ:

Dim People = {New Person {Age := 42, Name := "Erik"}, _
  New Person {Age := 12, Name := "Wouter" }}

It was only a matter of time until they admitted the power of the curly brace.  MUAHAHAHA! :)

To be more VB-like, I suggest:

Dim People = Begin Anonymous Type _
Begin New Type As Person(Age := 42, Name := "Erik") End New Type, _
Begin New Type As Person(Age := 12, Name := "Wouter") End New Type, _
End Anonymous Type As Anonymous Type

Tuesday, October 4, 2005 2:00:56 PM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [5]  | 

I just ran across this thread on TSS.NET.  I found it somewhat curious that there is a Microsoft guy on there claiming that DLinq is not an ORM.  While I don't doubt there's a way to construe the definition of ORM to make it not true (as the MS guys seems to try), I think that's counterproductive and just plain silly.  As one of the commenters said, it looks and feels like an ORM, so why not just call it that? 

At the MVP Summit, it was confirmed that LINQ will support extensibility into third-party tools via expression trees.  The problem is first that they don't have that stuff documented and second that they plan to change it.  This was gleaned in a session on DLinq where the product team was looking for feedback.  They're very concerned about getting feedback, as Dinesh has illustrated, about DLinq, but I think that they need to first focus on getting their API for extending LINQ (a la expression tree structures and the like) solidified and documented ASAP.

On that note, I've talked to Paul Wilson here at the ASPInsiders Summit about DLinq and the aforementioned blog by Dinesh.  Both of us have written ORMs, and both of us have commented on Dinesh's blog.  However, you'll note, neither of our comments have shown up.  I'm not sure what that's all about, but if you have feedback for the LINQ or DLinq team, you can post it here, and I'll make sure that the related teams are aware of it.  Now is the time to give your feedback on these products as they are early enough in the design cycle and are focused on that feedback.

Tuesday, October 4, 2005 11:23:48 AM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [0]  | 
# Monday, October 3, 2005

I guess since Plip already blogged about it, it's public knowledge now.  We've just heard about this revolutionary technology codenamed "Spang."  Of course, now that the word's out, there are parties within Microsoft trying to deny it.  Oh well, it is too cool, almost as cool as LINQ.

[Edited] It now appears there is a web site dedicated to this new technology...

['Nother Update] It seems that some of my colleagues think that a good clean hoax is somehow a serious issue, so our fun has ended.  Everybody just needs to lighten up!

Monday, October 3, 2005 3:46:17 PM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [0]  | 
# Thursday, September 29, 2005

Since its foundation eight years ago, ASPAlliance has provided articles, reviews, and code snippets targeting ASP and ASP.NET developers. In response to the increasing popularity of .NET and its easing of all kinds of development, ASPAlliance is diversifying to provide content spanning the full range of .NET development, from web to Windows to other devices.

To better signify this change, ASPAlliance is rebranding itself as the Active Software Professional Alliance. We will keep the ASPAlliance moniker, but instead of that indicating a specialty in ASP and ASP.NET topics, it will serve to indicate a more comprehensive resource for software professionals, particularly those interested in Microsoft .NET and related technologies.

So if you've got a hankering to do some technical writing, improve your writing skills through our editorial process, share your knowledge, make a name for yourself, and, to top it all off, make some money, go to our Write for Us page, review our guidelines, and submit an article proposal.  We're looking for articles, book, tool, and component reviews, code snippets, and sample applications that are of interest to .NET developers.  I'd love to see some articles on WCF, WPF, LINQ, or anything you think is really cool and want others to know about. 

Keep in mind that the proposal should be a reflection of your writing skills, so ideally, it will be a thought-provoking summary of what you'd like to write about using your best English.  Take a look at our guidelines to get a better idea of what we're looking for.  I'm looking forward to seeing more great content on ASPAlliance.com, so start thinking and writing.

I'm also always looking for ways in which we can make the reader's experience better.  As noted previously, we have stopped using article paging, we've made many performance enhancements, we've dramatically enhanced and streamlined the editorial process, we've made article submission and compensation better, and now we've broadened our focus to get even more great and interesting content.  But we know we can still improve, so please, email me any suggestions that you have about what you'd like to see from a high-quality .NET developer community site.  Would you like to see forums?  Blogs?  Send me your ideas!

Thursday, September 29, 2005 7:22:55 PM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [0]  | 
# Monday, September 26, 2005

There's some good stuff in the latest edition of MSDN Magazine.  I'm talking about the Memory Models article by Vance Morrison and the new Concurrent Affairs column by Jeffrey Richter.  If you don't have a computer science background, or maybe you do and just need a refresher, these articles will help to get you on track when dealing with some aspects of multithreaded programming.  

Mr. Morrison covers some useful low-lock techniques and offers advice of when to use them.  Mr. Richter covers one way to reduce actual locking and increase performance by not dropping to kernel mode using a spin lock, which Mr. Morrison also mentions.  Both of them do so in the context of .NET, including v2, so even if you're a threading expert, you may pick up some tidbits to be aware of when using .NET v2.

I'm also looking forward to reading Stephen Toub's article on High Availability as it appears to be another good one along the lines of writing high-performing and robust code in .NET.  Kudos to the authors and editors on this edition!

Monday, September 26, 2005 12:19:09 PM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [0]  | 
# Friday, September 16, 2005

I just finished watching the interview with Anders on Channel 9 about LINQ.  This is one of those things that your grandchildren will ask you about--where were you when you first learned about LINQ? 

Obviously, I'm using hyperbole, but I really do think that this is a huge step in the right direction.  I tried to implement something similar (and I say that loosely) with my DataAspects ORM query syntax.  My problem is that I was limiting myself to C# v1.1, so, for instance, I used an instance of the object to be queried as the source for the criteria of the query when getting a collection. 

For instance:

Order criteria = new Order();
criteria.Customer = myCustomer;
OrderCollection oc = new OrderCollection();
DataAspects.DataProcessor.FillCollection(oc, criteria, "GetOrdersByCustomer");

Suprisingly, this worked for a lot of simple cases, but it broke down for any kind of complex criteria so that you had to resort to ADO.NET and passing a data reader into the object collection builder.  But the key for me--the thing I wanted to achieve was to be able to build my query using all the nice features of VC# like type checking and statement completion.

Well, LINQ does that and a whole lot more.  The thing is that they, thankfully, were not limited by C# 1.1 but were able to invent C# 3.0 and .NET FX 2.0.  So they get to invent new keywords, syntax, etc.  Yeah yeah, I know.. the world's smallest fiddle...  But really, I'm just glad that it's here and that I don't have to worry about solving that problem. :)

One thing, though, is that they are going to go the route of attributes on classes to do the mapping (or so it sounded like), which I like (that's how I was doing DataAspects).  We'll see how that pans out.  Of course, they also will have the nice GUI-generated object layer for your database, which is one step above the typed DataSet.  It still doesn't recommend OOD as a application design philosophy, but at least, via mapping, we'll still be able to take advantage of these features that really are plumbing that we shouldn't have to deal with. 

I know there are different strokes for different folks, and there are plenty (probably most MS developers) of devs who like to start with the database for their application design (ugh!).  My own preference is to start with the problem domain and OOD and then worry about persistence later.  I've got an article submitted to CoDe on this topic, but if they don't want to publish it, I'll probably put it up on ASPAlliance or somewhere else.  In any case, LINQ will make OOP much, much easier and provide even stronger practical arguments for using OOD, and for that, I'm very thankful and eagerly looking forward to digging into it myself.

So if you haven't already, go check it out!

Friday, September 16, 2005 5:47:59 PM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [0]  | 

I just ran across a post today by some fella named Nick Hodges who has read the most controversial article I have ever written.  In his blog, as well as in many comments on the article, there seems to be some confusion as to the distinction between normalization in general and normalization using artificial integer keys.  A commenter named Jack on Nick's blog seems to understand this issue best.

In any case, I don't think I need to rehash what I've already said; just read the "Doggie Bag" section of the article to see what I thought readers should take away from the article.  It's very clear from that that I am not opposed to normalization, and in fact I even suggest in the article that there are certainly times where integer keys make a lot of sense.

As for my saying that lookup tables are "part and parcel with the second normal form, if you care about living up to such pedantry," which seems to have really fired up some folks, all I was saying is that I think a lot of insecure programmers try to use "big words" for vainglorious aggrandizement (how's that for big words! <g>) or to bully the lesser-knowledgeable types into agreeing with them.  It is, for example, like my going up to the average church goer and asking them what they think about the soteriological significance of the Christ event.  Most of them would just stare at me blankly, and I could feel very intelligent indeed.

I'm not saying that specialized jargon does not have it's place; quite the contrary, it is a very efficient way to express otherwise verbose ideas to those who are known to understand the meaning of the jargon.  However, if you are dealing with an audience that probably isn't familiar with the jargon, it is pedantry.  And that, friends, is why I said that in the article. 

There are many (maybe most) developers that don't understand the meaning of "second normal form," but they do know that good database design involves using lookup tables to avoid the repetition of data.  They don't need to know what "second normal form" means as long as the get the idea.

So, no, I was not trying to undo the concept of normalization.  In fact, that was only a fleeting mention in the article.  What I was saying, I still stand by.  There are times when it makes more sense not to use artificial integer keys.  If you disagree with that, I'm okay with it.  Just please don't go creating a bunch of straw men and starting rumors... 

Friday, September 16, 2005 5:07:28 PM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [2]  | 
# Tuesday, September 13, 2005

I was just looking at my blog today and noticing some of the ads in my Google AdSense.  There are ads for some 'universal church' and ads for some 'holy bull' blog.  Seems everybody's got a beef to pick with 'organized religion' these days.  It's kind of sad that we organized folks have screwed up so much to make people think that they need to come up with something new, but the idea is actually really, really old.  Gnostics have been around since the beginning of Christianity, each sect claiming some special secret knowledge ('gnosis') that you need to be perfect or what have you.

But we know that when questioned by Pilate, Jesus boldly stated that he had said nothing in private.  His teaching had been on the hillsides, on boats, and anywhere there were people who had an ear to hear.  The very nature of Christianity is the Gospel, which is literally the good news, and Christ instructed us to not keep it hidden but to be like a beacon on a hill and the flavoring of the earth.  Christians should know that there is no secret revelation that they need. 

The Church itself is held to the teachings of the Holy Scriptures and the deposit of the faith, what St. Paul called "the traditions which [we] were taught, whether by word of mouth or by letter." (II Thess. 2:15)  None of this is secret but is plain for everyone to see and hear in the Bible, the Church Fathers, Doctors, catechisms, encyclicals, pastoral letters, and so much more.  There is a public historical and doctrinal record of the Church from the earliest of times; there is an unbroken succession of bishops from the apostles to today.  Just think about it--literally, there is a physical link back to the apostles by the passing on of the ministry by the laying on of hands in ordination.

So I would not get too caught up in these new fangled organizations and individuals who claim to have some special knowledge about God that is all you need.  All of these indirectly depend upon the Church for their knowledge about God and Jesus, and what is in the Bible itself was decided by this same Church.  Without this 'organized religion', we would have no knowledge of God beyond that which the pagans have, which is, as St. Paul said, "written in their hearts."  But that would make the Law of Moses, the Prophets, and the Incarnation of no effect--God revealed himself first through the Law and the Prophets and later by becoming one of us, not only to redeem our human nature but also to make himself better known to us. 

This revealed knowledge of God would be unknown to us without the so-called 'organized religion' so often anathematized today.  So even these who claim we don't need organized religion contradict themselves as they partake of the knowledge of God we have from Revelation afforded by organized religion.

Similarly, I would not be too keen on new organizations claiming to be 'universal', meaning they have no creed or doctrine and 'accept' everyone.  The Catholic Church is universal, not only in name ('catholic' coming from the Greek for 'universal') but also in reality--it stretches to every part of the earth.  It is also accepting of every individual as a human being with dignity, made in the image of God, loved by God, and able to receive the grace God offers through the Sacraments. 

Accepting and loving someone does not mean you have to approve of and love everything that person does.  Somehow this is confused all too often these days, part of the post-modern, relativistic mentality so popular in our culture.  I would suggest that loving someone means more than just hugging them and saying so; it means also that you sincerely want what is best for them and that you will try to help them become the best that they can be.  Sometimes this means letting them know that what they are doing is not the best for them.

So no, no thanks.  I think I'll keep my 'organized' and 'universal' religion.  We may not be perfect, but we are trying to be.  We are trying to grow in love, joy, peace, and the other 'fruits of the Spirit', but it is a process that most of us will not complete until we enter those pearly gates and behold the face of God.  We're not happy to just be as we are--we want to be all that we can be through the grace of God.  Now doesn't that sound better than being alone or simply patting each other on the back all the time while being internally miserable?  I think so...

Tuesday, September 13, 2005 7:59:50 PM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [2]  | 

The Web Platforms and Tools team at Microsoft just went live today with their first public preview of Atlas, which is a server-side API for asynchronous call backs in Javascript to work with ASP.NET 2.0.  Right now, it only works with .NET 2.0 Beta 2, but they intend to follow up soon with a build that works with the PDC bits.

Tuesday, September 13, 2005 11:56:06 AM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [0]  | 
# Saturday, September 10, 2005

I was recently reminded of the paradox of the relativist, which is the insistent assertion that there is no objective truth, that is, truth that applies equally to everyone.  The paradox, to be painfully evident, is that one cannot say, on the one hand, that there is no objective truth while, on the other hand, claiming the objective truth that there is no objective truth. 

One could come up with any number of pithy sayings to this effect, but to say it right out may be more productive: relativism has no rational or moral grounds on which to stand and judge other ideologies.  It is self-defeating.  Essentially, it is an irrational plea against reason and truth; it is an abandonment of reason in favor of such conflicting impulses as practicality, compassion, selfishness, and humility.

Don't mistake me.  I am not saying that relativists are inherently evil or even that they're any worse, humanly speaking, from the average exclusivist.  There are plenty of good people who adhere to this philosophy, some of which are my own friends and family members.  Most people do not critically think about their philosophy—they just go with the flow. 

And the flow these days is with relativism, as is supremely evident in the mass media and just as evident in the conversation of everyday folks.  There is the implicit assumption that we cannot “judge” others’ way of approaching life (that is to say others’ philosophy), that what may be true and best for me is not true for others.  To say otherwise garners almost immediate anathema or, at the very least, shock and awe.

At the same time, I wouldn’t say that there aren’t any opportunists that use relativism for nefarious purposes.  Surely there are.  And surely there are those who, when relativism is challenged, shy away for less than laudable reasons.  After all, if I can’t tell you that what you think or how you act is not good, you can’t tell me either.  Thus, each of us gives the other a moral carte blanche to do what we will as long as we don’t hinder each other in our pursuit of pleasure.

But truly, I’d say almost any philosophy can be abused; however, abusus non tollit usum—the abuse of a thing does not nullify its proper use.  The real question for the thinking person is whether or not relativism is the best approach to life, even when it is at its best, even when it is held for praiseworthy reasons. 

This question should be applied to any philosophy, including Christianity and other religions.  How often do we hear so-called arguments against religion that ultimately boil down to abuse of it?  The answer, simply put, is almost all the time; it is rare to hear a rational argument against religion that does not hang on its abuse.  But I will not fall prey to that temptation in this essay; I will consider what is good in relativism and show how its good is not peculiar to it and how it is essentially flawed. 

Relativism is expressed in so many superficially beneficent ways as, for example, wanting to legalize same-sex marriages, wanting to exterminate any apparent endorsement of particular religions, not wanting to "judge" anyone, etc.  At its heart is a seemingly ultra-rational principle, i.e., "I might be wrong."  As an example, in response to a previous post of mine, a reader expressed concern that I might actually hold to something I consider to be objectively true; he said “the definitive tends to make me uneasy, so from my perspective, your certainty increases my uncertainty.”

I think most people who hold to relativism do so out of good will and humility to believe they might be wrong and to avoid “judging” another.  I would also wager that its popularity today is chiefly due to human history that involves people who injure and kill those who disagree with them.  Humanity has a very bad record when it comes to dealing with those that disagree with it.  And that is, while a compelling non-rational motivation, still based in the logical fallacy of abusus non tollit usum.

This historical facts—the abuse of humans at the hands of other humans—are rather an argument against relativism.  Relativism implicitly assumes that humans are innately good; otherwise, it would not follow to believe that what another believes is ipso facto good for them.  Our history shows quite unabashedly that humans are anything but innately good; it is patently clear that our nature is to be selfish at the cost of others.  So we cannot presume that another’s philosophy is okay, and once we acknowledge this, we are forced to judge others’ philosophies (and our own) to endeavor to find what is a good philosophy for us all.  And thus relativism falls flat.

Ultimately, relativism is a self-defeating philosophy that no rational person should cling to.  Any attempt to rationally think about it and apply it causes innumerable contradictions, and the goods that make relativism so popular today, i.e., good will, charity, compassion, and humility, are goods that are promoted by other more consistent philosophies.  Indeed, there are perfectly good exclusivist philosophies that do not require the extermination of all who disagree.  Christianity, despite claims to the contrary, is one of these.

One can happily and reasonably believe in the existence of a personal God, that Jesus is who he is reported to be, that the Church is who she claims to be, and in all the consequent doctrine without being forced to believe that one must force that faith on others.  It is certainly true that some have believed that force should be used to convert others, but they are far and away a minority in Christian history.  And especially today, that belief is virtually non-existent. 

Nor is it necessary to believe that all who are not active church members are damned to hell.  Of course, this is contested by some fundamentalists today, but they are still a very small minority.  Unfortunately, this is the view that logically leads to the idea that force is acceptable because, after all, if one believes another is damned if he doesn't believe as you do, that person loses his human dignity and can therefore be treated as less than human, either to be exterminated or forcibly converted.  But the Christian Gospel is anything but that. 

Quite the contrary, one can have all the aforementioned virtues implicit in relativism, while still maintaining a rational ground to stand on.  Good will is at the heart of the Gospel.  At the Nativity of Christ, the angels proclaimed the message of peace on earth and good will to men (or to men of good will, depending on your translation).  Charity is the chief virtue of Christianity—St. Paul wrote that even if we have all the wonders of heaven and its virtues, without charity, they are empty.  Compassion is the central motivating factor in the Incarnation and ministry of Jesus, and we are called to share with Jesus in his passion (his suffering) as well as the suffering of the least of us (the poor).  Humility is also a virtue implicit in Christianity—we are all fallen human beings in need of God’s grace and all the good that we have comes from God, including our talents and abilities.

So you see that Christianity has all that commends relativism without requiring one to believe what is patently false and irrational—that what someone else believes is inherently good for them and that their beliefs are just as good as your own.

I am convinced that we must believe in something to give meaning to our lives.  This is not a desperate, irrational cry but a stark reality, for if we do not believe in something, we are merely automatons driven by our nature, no different than any other animal, plant, or protozoa.  And if we believe in something, we must believe it is better than believing in something else (or nothing) because if we did not think so, would we not believe in the something else that we considered to be better?

Truly, it seems clear that by choosing to believe in one thing over another, we are implicitly asserting that we believe it to be superior to another belief.  And if that is the case, why not say so?  Why should we falsely and irrationally claim something to the contrary?  Can we not say so without being arrogant?  I think we can.

Whether or not we are arrogant is not a matter of being exclusivist but rather in how one approaches interaction with others.  Surely we all recognize when one athlete is better than another, and often, athletes know this just as well as we do.  But that does not make them arrogant.  Demonstrating their abilities does not make them arrogant.  No, arrogance is a matter of attitude, in sports, in the workplace, and at the table of philosophical dialogue.

You can believe that your philosophy is better than mine.  In fact, you can believe that your philosophy is the best for the entire human race.  You can do this without being arrogant.  You can even attempt to demonstrate how your beliefs are best without being arrogant.  What makes you arrogant is how you do this.

Would it be arrogant for me to try to force my belief on you?  I think so.  Would it be arrogant for me to dismiss your beliefs?  Yes.  Would it be arrogant for me to make snide remarks and jokes about what you believe?  I tend to think so.  There are all kinds of ways that we can be arrogant, and in doing so, we can easily kill any productive dialogue.  But simply adhering to a set of beliefs and believing that they are the best for everyone is not arrogant.  It is logical.

So what say we stop patronizing each other and try to convince each other again that what we believe is best?  How about we quit stifling valuable, productive, and enriching dialogue?  Let’s be honest with each other and ourselves and see that we truly do believe in what we believe, and that what we believe is worth believing more than the alternatives.  But let’s also remember to do so in a spirit of good will, charity, compassion, and humility.

Saturday, September 10, 2005 3:39:02 PM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [2]  | 

For the rare among you who may be wondering if I did ever get the car, the answer is yes.  I just have been preoccupied. :)

So here it is:

The Car

It is as fun to drive as you might imagine, and quite roomy and comfortable for being a small car.  I could talk about it for a while, but I won't bore you.  If you're ever in the market, though, I definitely recommend it. 

And I promise to get back to writing about more interesting topics soon.  I actually had a whole article written yesterday, but when I asked my wife to look over it, she accidentally navigated away from the page, and I lost it.  Argh!  That's the second time I've done that.. you'd think I'd learn.  Well, the problem is that when I copy & paste from Word, it brings a bunch of crap over into the HTML, so I don't like to do that.  But if I paste into notepad, e.g., it loses hyperlinks and such.  I can't win, but I think I'll be erring on the side of extra markup from now on. hehe   

Saturday, September 10, 2005 1:32:21 PM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [6]  | 
# Wednesday, August 17, 2005

I just heard about the new Nullable type runtime feature being introduced in the August CTP.  That is too cool!  I was initially quite happy about the nullable types provided in 2.0, but after trying to use them, I found them somewhat cumbersome, particularly when dealing with a data reader.  I'm not sure that this change will help that problem much, unfortunately, but it definitely addresses a key pain point for nullable types.  Thanks to MS for listening to the community and making the painful change to make everyone's lives easier! :)

Wednesday, August 17, 2005 9:51:45 AM (Eastern Daylight Time, UTC-04:00)  #    Disclaimer  |  Comments [0]  | 

Disclaimer
The opinions expressed herein are solely my own personal opinions, founded or unfounded, rational or not, and you can quote me on that.

Thanks to the good folks at dasBlog!

Copyright © 2019 J. Ambrose Little