# Wednesday, January 6, 2010

image

The NYC developer community is proud to announce our 4th (sort of annual) Code Camp to be held on Saturday, March 6, 2010, from 8:00 AM until 6:30 PM. It will take place at the Manhattan Microsoft office on 6th Avenue across the street from Radio City Music Hall. We’d love for you to submit a session.

We have our call for speakers open from now until February 5th.

To apply for a speaking slot, first please register as a speaker here: http://tinyurl.com/nycspeaker

Then with the email address you registered with on our speaker page, please add as many abstracts as you like here: http://tinyurl.com/nycsession

Submit on anything you like in the .NET space, there is no central “theme” to our Code Camp except .NET development!

Unfortunately we can’t afford to pay any T&E, but we will stuff you with lots of pizza and soda!

Technorati Tags:
posted on Wednesday, January 6, 2010 3:06:43 AM (Eastern Standard Time, UTC-05:00)  #    Comments [0] Trackback
# Tuesday, January 5, 2010

Happy New Year! Keeping with tradition, here are some predictions for 2010 in the Microsoft Software space.

2010 will be remembered as a “tipping point” year for three things in the Microsoft space. I am not saying that on December 31st, 2010 you will sit back and say I am right on all of these, but I am saying that by December 31st, 2011 or 2012 you will. That said, 2010 will be the tipping point for:

  • Moving beyond .NET
  • Business Intelligence for the masses
  • The Cloud

Today I will look at the first item and tomorrow I will talk about BI and the Cloud.

Moving beyond .NET

Here are some no brainer predictions. Visual Studio 2010 and .NET 4.0 will ship and a lot of developers will be happy. Microsoft will also be happy since adoption will be high. Here is the not so obvious prediction: 2010 will be the year where .NET begins its decline and its replacement starts to shine.

Huh?

Let’s face it, .NET is old. This summer will mark 10 years since its debut at the 2000 PDC. It’s been in production for 8 years. That is like a century in computer time and a millennium in Internet time. Billy Hollis put it in perspective for me a few weeks ago at dinner: more time has passed since .NET 1.0 to today than between VB 1.0 to VB 6.0. VB 1.0 was introduced in 1991. VB 6.0 was introduced in 1998. That is 7 years. .NET shipped officially 8 years ago in February 2002. (This also means that I have been coding longer in C# than VB, but I digress...)

Second .NET is “hard”. What I mean by hard is that the framework has bloated: there are too many namespaces, too much “legacy”, and too many ways to do the same thing and we have lots of conflicting advice on what “pattern” is the best. Developers are confused if they should use ASP + AJAX or MVC or something else. They are also scared that if they build an app they will be mocked on the latest “expert” blog saying that their implementation of the MVVP pattern is a newbie mistake and they should follow the MVVQXDP pattern. Java and LAMP are no better. PHP on the other hand, once left for dead, is back with a vengeance. Why? It is easy, just like ASP classic. At the end of the day developers just want to get apps written with ease.

So what is going to replace .NET?

Silverlight + RIA Services + DSLs.

While Silverlight looks and smells like .NET, in reality is not. Ever try to use ADO.NET in Silverlight? Do something with data access that is not asynchronous? Silverlight is its own framework that borrows a ton from .NET, but itself sits just outside the full framework.

Silverlight will continue to evolve into a rich media, cross platform web based application platform with the release of Silverlight 4.0. While 2010 may not be remembered as the year of great Silverlight adoption, SL 4.0 will be remembered as the tipping point, much like VB 3.0 was for the Visual Basic platform. Speaking of VB 3.0, VB 3.0 did not get popular until the “database compatibility layer” shipped. (Wow I am dating myself here!) With VB 3.0 + the “database compatibility layer” or in reality, the JET database engine and DAO, VB moved from being a “toy” to a full fledged programming platform for business. When the db compatibility layer shipped for VB 3.0, adoption was not immediate, but when you look back, it was the one thing that started the VB revolution of building line of business apps.

RIA Services is Silverlight’s database capability layer. Just like Jet and DAO made it easy for a developer to connect to databases, perform CRUD operations, data bind, validate, and do it fast without complicated libraries, RIA Services will allow you to do all of that easily in SIlverlight. Silverlight 4.0 and RIA Services will ship this year, most likely sometime before the summer. I don’t think that at the end of 2010 you will be saying “this was the year of Silverlight and RIA Services” but in a few years when all we do is Silverlight you will remember Silverlight 4.0 and RIA Services as what started the Silverlight revolution in building line of business apps. Purists will say that RIA Services is not elegant and continue to code things manually. That is ok, purists mocked VB too, but just remember that for most of the 90s, VB ruled LOB apps in the enterprise.

You maybe thinking, Silverlight to replace .NET? But it is too close to .NET and has lots of .NET interop, etc, in order to work. (For example, to have RIA Services work you need a .NET server with WCF and EF 4.0, etc.) That means that .NET will be around forever! Well yes and no. Remember back to .NET 1.0, we had to use COM Inerop a lot to get a lot of things done. Or .NET wrappers for Win32 stuff. Not until .NET 2.0 (its 3rd release) did we really develop “pure” .NET applications.

Silverlight will continue to evolve and due to the influence of Ruby (as well as Rails), you will see more dynamic language support and DSL capability built into Silverlight moving forward. In the not too distant future you will start to build your XAML with a DSL: “give me CRUD screen connected to the Customer entity.” Then you will start to use DSLs to build your application’s business rules, workflow and control flow. After that you will build you application’s own meta-language, the equivalent of an API, allowing others to hook right into your application’s logic. What will this DSL/dynamic language be? IronRuby? Something from Oslo? I am not sure. That will be in my predictions next year. :)

Stay tuned for predictions on BI and the Cloud…..

Technorati Tags:
posted on Tuesday, January 5, 2010 4:35:11 AM (Eastern Standard Time, UTC-05:00)  #    Comments [6] Trackback
# Tuesday, December 29, 2009

Looking forward to 2010, but here is a funny year in review from our friends at JibJab:

Try JibJab Sendables® eCards today!
posted on Tuesday, December 29, 2009 11:42:00 PM (Eastern Standard Time, UTC-05:00)  #    Comments [0] Trackback

With long  travel delays due to snowstorms and terrorism, I got to catch up on some of my reading. One book I read over the break that stood out was an unexpected one: Essential Silverlight 3 by Ashraf Michail. I say it is an unexpected one since the book is not about building business applications with Silverlight so you won’t see a chapter on MVVM or using WCF and asynchronous services. What you will see is a discussion of the internals of Silverlight, the guts of a ZAP file, and how media, layout, text, input, data binding, and the like work.

You maybe thinking, “I am a developer, I don’t care about vector graphics!” I thought the same but read the book anyway and learned a lot about how Silverlight works and how to best debug and performance tune an application. Maybe I am biased since I work at a company that has to know all of the details of the .NET framework to make our products work, however, I think that every developer should take a look “under the hood” and see how Silverlight works.

Ashraf has a very engaging writing style and the book is a quick read, I read it over the course of two or three days (on airplanes and in airports!) He breaks down the chapters really nice and the last part of each chapter is called “under the hood” where you learn something about the internals of Silverlight. I must admit that I did skim some of the advanced material about animations and wrote a note to come back to it if I need to, but the chapters on vector graphics, GPU acceleration, the Silverlight application architecture, and data binding were truly fascinating and will help me with all of my business applications.

If you are new to Silverlight this is the first book you should read, then pick up a book on building applications with Silverlight. If you have been using Silverlight for a while and want to take your development to the next level, read this book as well-epically the “under the hood” sections.

Lastly, if you use Silverlight in a Virtual PC, you will care about vector graphics!

image

Technorati Tags:
posted on Tuesday, December 29, 2009 6:35:08 AM (Eastern Standard Time, UTC-05:00)  #    Comments [0] Trackback
# Monday, December 28, 2009

About a week ago, I showed a simple demo on my blog of SQL Server PowerPivot for Excel, or just PowerPivot for short. I used SQL Azure as my backend and just did a mapping to a few Northwind tables and then built a pivot table using the Order Details table.

Today I will take that example one small step further and write a custom TSQL query and build a more advanced pivot table against that data source.  In a future post I will build a PowerPivot example against a true OLAP Cube, but that will have to wait for the new year. :)

Here is a TSQL query that shows an Order and joins to get the Product Name and Category as well as the Employee and Customer names. We also do a DATEPART() to get the order year off the Order Date. In addition we also calculate the Total Price. This will allow us to do many different sorts and groupings in a pivot table. The TSQL is here:

Select
od.orderid, o.orderdate,datepart(MONTH,o.orderdate) as OrderMonth,
datepart(YEAR,o.orderdate) As OrderYear,
emp.FirstName + ' ' + emp.LastName as EmployeeName,cust.CompanyName,
cust.City, cust.Country,
cat.CategoryName, p.ProductName,
((od.UnitPrice*od.Quantity) * (1-Discount)) As TotalPrice
from dbo.[Order Details] od
    inner join dbo.Products p
on od.productid=p.productid
    inner join dbo.Categories cat
on cat.CategoryID=p.CategoryID
    inner join orders o
on od.orderid=o.orderid
    inner join dbo.Employees emp
on emp.EmployeeID=o.EmployeeID
    inner join dbo.Customers cust
on cust.customerid=o.customerid

Now we have to connect to our SQL Azure database in PowerPivot. To do this, follow the instructions I placed on my blog last week to connect. After you connect, instead of choosing tables to connect to, choose the query option. Put in the TSQL from above and give your query a friendly name like Steve1 in PowerPivot (or rather NorthwindOrderDetails since we will be using this in our pivot table). Now you can use this query and its data to build a pivot table.

image

Building the PivotTable is pretty easy. Let’s use the TotalSales as our main value and Category Name and Product Name as our row labels. That means that we will see Category and be able to drill down into Product and get a sum for that category or product for each City (the field we choose for our column.) In addition we added a filter for Country that will allow us to see a drop down of each Country and we can filter for as many countries as we want. Lastly, we can add a “vertical slice” of Order Year that will add an additional filter in a graphical style. This filter is applied after your main filter (Country.)

image

I did this part in under a minute. This gives the user an extremely powerful pivot table and the ability to do some pretty sophisticated drill downs and filters. In addition, it is pretty easy to add/remove even more data (Customers and Employees for example) to this pivot table.

image

Enjoy!

posted on Monday, December 28, 2009 5:33:56 AM (Eastern Standard Time, UTC-05:00)  #    Comments [0] Trackback
# Sunday, December 27, 2009

Here is a special holiday message from Telerik!

PS: I did not make the video cutoff due to travel delays from Hong Kong to the snowstorm on the East Coast.

Enjoy!

posted on Sunday, December 27, 2009 9:26:59 PM (Eastern Standard Time, UTC-05:00)  #    Comments [1] Trackback
# Monday, December 21, 2009

At the PDC Microsoft released the Sync Framework Power Pack for SQL Azure tool. It is a tool built on top of the Sync Framework 2.0 that provides a wizard to keep an on-premises and SQL Azure database in sync as well as a Visual Studio template where you can take a SQL Azure database offline using SQL Compact (or whatever they call it these days.) Lets take a look at the data sync wizard today and soon look at the Visual Studio template.

I started the wizard via Start|Microsoft Sync Framework|SQL Azure Data Sync Tool for SQL Server. The wizard works by taking a database that is on-premises and creating a new one in SQL Azure and creating the SQL Agent jobs to keep them in sync. I could not find out how to sync two identical databases that already exist. To get started you need to provide your SQL Azure credentials and then the name of the new database that you are going to create in SQL Azure.

image

After you provide your credentials for your local server and select a database, you have to select a database to sync with. The next screen shown here allows you to select the tables you want to keep in sync. You also get to choose who wins in a conflict, the local server or SQL Azure.

image

Next you get to choose the order of your sync. This is a very smart feature, you get to say sync in this order to avoid the classic order detail missing order id problem.

image

After you finish up the wizard, it will go ahead and create the new database in SQL Azure for you as well as the tables and associated tracking tables. It will also create the SQL Server Agent jobs required to keep the data in sync. I noticed that on my local server I did not have SQL Agent running, so no sync was performed and after the wizard ran I had no data. So I had to go into SQL Server Agent and enable it and change the default schedule of my job (which was daily at midnight.)

image

You may want to get more creative with the SQL Server Agent schedule depending on your environment, however, the Data Sync wizard is a handy tool to get you started.

Enjoy!

Technorati Tags:
posted on Monday, December 21, 2009 5:59:41 AM (Eastern Standard Time, UTC-05:00)  #    Comments [0] Trackback
# Saturday, December 19, 2009

While I love Northwind, would do anything for Northwind, I realize that there really is not enough data in Northwind for meaningful demos. We’ve been using Northwind for 15+ years and the reason why we have not completely abandoned Northwind is because AdventureWorks is such crap. Someone at Microsoft took a relational pill one day and over relationalized AdventureWorks to 100th normal form. It takes about 7 joins to get a list of unique customers and their mailing addresses. Microsoft has admitted their mistake and given us “AdventureWorks Lite” a slimmed down version of AdventureWorks with less joins and less pain in the you know what. (Only 3 joins to get the customers and their mailing addresses.) In addition to ADLite, Microsoft has also given us a data warehouse version of AdventureWorks in star schema for BI testing called AdventureWorksDW.

You can now easily load these databases into SQL Azure. The databases were released on CodePlex along with a loading script that you have to run from the commandline. Be careful, the Datawarehouse database is larger and can cause a timeout on a slow connection, forcing you to do it over again.

image

Enjoy!

posted on Saturday, December 19, 2009 9:45:12 PM (Eastern Standard Time, UTC-05:00)  #    Comments [0] Trackback
# Friday, December 18, 2009

The Astoria (aka ADO.NET Data Services) team released an updated .NET 3.5 SP1 version of Astoria the other day. There are tons of great new features like projections and my favorite, an inline row count. As I said on my blog yesterday, you have to alert Astoria that you want to use the new V2 features, by default Astoria 2.0 runs in Astoria 1.0 mode. (For backwards compatibility.)

Telerik has enhanced the Data Services Wizard to support Astoria 2.0 (officially the “Data Services update for .NET 3.5 SP1” but I digress….)

Now if you have the updated Data Services DLLs on your machine, you will have the option to create a service using V1 or V2. If you choose V2, we will automatically set the MaxProtocolVersion property to V2 for you.

12-17-2009 5-38-01 PM

Happy Data Servicing!

Technorati Tags: ,
posted on Friday, December 18, 2009 5:41:52 AM (Eastern Standard Time, UTC-05:00)  #    Comments [0] Trackback