Thursday, September 15, 2005

LINQ

Atlas is one of my favorite technologies announced in the PDC, with Windows Workflow Foundation comming close. Of course, I hope to get a chance to play with the Expression tools and with Office 12 soon.

But in my opinion, the most important announcement from the PDC is LINQ.

C# and VB become mixed functional/object oriented/imperative languages.

The data impedance mismatch is over. Rumors about this being ripped from Foxpro and 4GLs are largely wrong. This is much more elegant and powerful. As a developer, this is a happy day.

I have read some people concerned the idea that LINQ, specially DLINQ will push .NET develiopers to mess up the layered architecture.

You don't only isolate concatenated SQL in a DAL component for aestetic reasons.

You do it, for instance, for the abstraction and the scalability provided by a special execution environment.

But with LINQ the "functional power" of the query language is not anymore limited to data that is on the database. You can now use the same language constructs to query any data, regardless of location.

Thanks to all the teams that made this happen. You can count on me giving you feedback.

First two pieces of feedback:
  • I want to see transactions to become a first class citizen in the CLR.
  • I hope to see many legacy database 4GLs (includding FoxPro) to adopt the CLR as a runtime. Now that the CLR comes with queries, it can be a true life saver, both for the products and for the developers that mantain those billions of lines of code.

Sunday, September 11, 2005

In support of Adam Barr's idea for opening current Microsoft Office formats

His post is here: An Open Letter to Jeff Raikes

...

No doubt you're aware of the recent fuss over Massachusetts' decision to require open formats for its official documents. Microsoft's predictable response was to plead confusion, hurt, and sorrow for the innocent users forced to abide by such a policy. I have another idea. Instead of responding like a sad puppy, Microsoft should embrace what Massachusetts is proposing.

...

No, I'm saying that Microsoft should go back to the fundamental reasoning behind the Massachusetts decision, and embrace that. Massachusetts is not adopting OpenDocument for its own sake; it is adopting it because it meets a set of criteria the state has established--criteria which Microsoft could also meet if it chose to.

...


I like the idea and this post is in support of it. Times change quickly, and what still fitted in Microsoft's Business Model a couple of years ago, is turning against it now.

At first I thought that licensing the formats only for reading and not for writing sounded too restrictive. But then I realized that he is talking about the current formats, that are already becoming obsolete. The new formats are already being developed as open standars.

UPDATE: I have just added this to Adam's post comments:

I am not sure there is such a thing as delusional blogger self-importance disease. When I do test software, if I have a bug to report, I report it. I don't loose my time thinking that a tester smarter than me already found it and reported it. Nor do I think a developer smarter than me coded the feature and I must be crazy to think it is broken.

Classical Office formats are about to become obsolete, and there is no real business reason to keep them in obscurity (I can imagine possible security reasons, but I am not sure they exist). There is a real business case in opening them, though.

Actually, I have similar feelings about Microsoft not including MFC and ATL in Visual C++ Express, but then, I don’t work for the company...

Good luck to everybody in the PDC

I am green with envy, but good luck anyway ;)

So, is it LINQ or IQF?

I have read about it before at Luca Bolognese's blog, and news from it are coming in pieces from conversations in the PDC.

Sometimes referred as Integrated Query Framework, sometimes as Language Integrated Query, or maybe as Common Query Runtime (this one is foggy in my mind).

Whatever the name is, this new .NET feature is coming out more less the way I hoped it to be.

UPDATE: I found that the original post in jpox.blogspot.com has been deleted. I guess it was not correct information or maybe the author decided to help keep the secret.

We will see soon anyway.

UPDATE: Updated link sent by Joris. Thanks!

Tuesday, September 06, 2005

Eureka! Integrate your custom ADO.NET Provider with Visual Studio 2005, using Data Designer Extensibility (DDEX)

I have been looking for this information for some time. The fact that I could only find it tonight (when it has been published since May) is proof that there is not enough "hyperlink glue" among the words in the subject out there in the Web.

The sole purpose of this post is to provide some of this glue, so you can find the information more easily from now.

I once tried posting a question on Steve Lasker's team Smart Client Data blog:

What do I need to add to a custom ADO.NET provider to get design-time support in your tools?

But unfortunatelly my comments were deleted, likely by an anti-spam filter.

Just for the record: Once again, I think the tools provided by the Visual Studio Data Team (I don't recall the exact name of the team right now) are great, and I would say this to Steve Ballmer and Bill Gates if they asked me :)

But I am guilty of wanting more features and more openess in the development tools I use everyday.

Tonight I finnaly found a clue in this blog. There, someone talks about receiving some information from Microsoft on how to integrate a custom ADO.NET provider with Visual Studio. That someone does not actually uses the name Microsoft , but that very mature M plus a $ dollar sign thing. The post contains no link nor a detail about any API. It even says "ad.net" instead of ADO.NET. Now I cannot remember how I managed to find it!

A few minutes later, I got some inspired search string in Google (or was it MSN Search?). And here are the results!

So what is DDEX about? It is simple:

If you created your own "custom" ADO.NET 2.0 Provider and what it to be listed and exploited by the many design-time data tools in Visual Studio 2005 (like Server Explorer, Typed DataSet Designer, Data Sources, etc.) it wont be enough to add your provider to Machine.Config. You will need to create a "Provider Provider" using Data Designer Extensibility (DDEX).

I will probably be helping test this with an office mate tomorrow. He wrote our ADO.NET Provider.

Friday, September 02, 2005

MSDN Product Feedback closing bugs and suggestions at full speed

They add a message asking us to send them an email with the FDBK code, so they keep track of the issue!

At first glance, this looks as a very silly way of using your bug/suggestion tracking system. Why not just postpone the review for the next iteration and keep it in the database?

Why do you need to clean up the bugdatabase?

Is it a law at Microsoft that the database must be emptied of pending (no matter pending for when) items before RTM, or what?

Thursday, September 01, 2005

Hacking CSS

Start.com (Update: Wow! They have a new address, and they are looking even better!) has been my home page for a while, both at home and at the office. It is the only thing out there that is better for me than about:blank. It is not very fast to load, but it loads much content in an asynchronous way (the A in AJAX). It is full of nice features and ticks and I am a such a newbie in Web development. It is difficult to even imagine how they do all this.

fortunately, there I met Scott Isaacs' blog. His insights are a little different than the others. Here, for instance is his post about how to do wonderful things in CSS without the hackery we are used to get from others. You should read Scott post, but for short, he recommends you get the server to inject special class attributes on the HTML tags, including the browser type and version. This way you can use html.browsername.version selectors on your CSS for style sheet that are tailored to a specific browser.

Scott's timing is excellent. I am doing a lot of ASP.NET 2.0 programming, and in the meanwhile I am learning CSS. I should better say that I have already learned CSS, and I am still learning how bad current implementations are. I am hating it, and I was about to go to the dark side, when Scott saved me.

Thanks a lot!

Anyway, I am open minded regarding any hack that would provide me a decent "abstraction layer" and that would offer reasonable forward compatibly.

UPDATE:

I just want to add a very simple implementation of this pattern for ASP.NET 2.0:

I put this on my default master page:

<body class="<%= Me.GetBrowserCssClass %>">

I am not using the HTML tag as Scott suggests because VS says a class attribute there breaks the standard.

Then I add this to the code behind class:


Protected Function GetBrowserCssClass() As String
If Session("BrowserCssClass") Is Nothing Then
Dim b As HttpBrowserCapabilities = Request.Browser
Session("BrowserCssClass") = _
LCase(b("browser") & _
" m" & _b("majorversion") & _
" d" & Replace(b("minorversion"), ".", "", 2) & _
" " & Left(b("platform"), 3))
End If
Return Session("BrowserCssClass")
End Function

I am not sure saving the string in the Session is a good thing. I think the Capabilities collection is going to be populated anyway, so it is possible as much work to retrieve the string from the session as it is to build it again. Only testing would tell.

And I know the way I create the string is a little naive, but it works with what I have at hand for testing. I don't know how the platform string looks for browsers running in other operating systems.

My blogger atom feed does not work

It is still stuck showing my "blog depression booklet" post at the top. I wonder what can go wrong Blogger software. Maybe this post helps.

Update (September 9, 2005): No response yet from Blogger Support (does it even exist?), but I found the solution. Blogger just changed the feed address. It switched from http://diegov.blogspot.com/rss/diegov.xml to http://diegov.blogspot.com/atom.xml. The old feed still exists, but it is dead. If the sent any notice, I missed it.

Tuesday, August 30, 2005

As I said, where is WinFS?

Well, actually, here it is, on all its glory, and of course, alive and kicking:

Another piece of feedback was concerns over the WinFS api’s being a different data access pattern than our existing managed code data access APIs. Further, that our APIs were not aligned with broader data platform needs like OR mapping. This was a big one, and as you explore the SDK and the APIs, you will see the beginnings of how we will be addressing this. We are in the process of building-out the next version of ADO.NET to have new features that provide a data model, object-relational mapping, and flexible query infrastructure. The new data model is about entities, and the WinFS data model of Item types is built on that model. Looking through our SDK and code samples you will see how Items are composed of underlying entities. OR mapping is a big requirement - WinFS is a very prescribed mapping (defining a type in WinFS generates both the underlying storage schema and the partial class to program to that type). But the real-world has lots of requirements for flexible mapping – to existing data, to existing objects, etc. On query, many of you have heard about Anders Hejlsberg’s work on Language Integrated Query – and the new ADO.NET functionality will plug directly underneath so that you can use the new query patterns on any entity data, including of course now WinFS Items.
So, my personal understanding is that ObjectSpaces and C-Omega evolved and became the Integrated Query Framework, which is tightly integrated wth the CLR and the .NET languages. At the same time WinFS will be built on that, instead of using previous technology.
So, I guess part of the reason WinFS was delayed was they found that it made more sense to wait and get it right from the beginning. Then, I am grateful!

Monday, August 29, 2005

So, it wasn't that boring, Luca!

I was wondering what Luca Bolognese was really doing in the C# Team after Microsoft apparently ditched ObjectSpaces.

Now that the name of .NET Language Integrated Query Framework has come out, I think it could be the coolest piece of software of 2006. I mean the coolest piece of software for us doing database related development.

And now, what happened really to WinFS? Suddenly the pieces are fitting in place.

Monday, August 01, 2005

Blog Depression Booklet

Update:

This is the last post included in the old site feed http://diegov.blogspot.com/rss/diegov.xml.

Please subscribe to the new feed: http://diegov.blogspot.com/atom.xml.

I found this PDF file through Scoble. It is actually fun, but also nice and consoling and an even more fun way. The darn whole paragraph stinks!

It is the first time I have the notion idea (you really like cursi words, don't you?) that probably every blogger feels its his/her blog sucks. Its? yeah, I know what you mean... It is not that it had me too worried! It has been a while since I decided I would just let my blogging flow. ...And it shows!

Moving to MSDN

I haven't decided yet, but it is very likely that I will stop blogging here for some time. For some background, I have moved to the sate...