Thursday, May 14, 2009

Weather modeling or web services aim to conserve power - Narendra Bhandari Intel

This is one of eye opening keynote. Just compiled some of the highlights from my twitter.

How S/W developers code programs has dramatic impact on power consumption in Data centers.

Loop vs Service has big impact on power.

It is time S/W professionals understand hardware chages taking place in hardware side of industry.

Dual Core to Multi Core to Many Core. Wether modelling to webservices everone need to optimise for sake of conserving power.

Visual Adernline, Intel Parallel Studio performance Tools from Intel to take advantage of hardware advances. Most of the tools are developed like VS2010 plug-ins and thus bring lot of value with simplied learning curve., and Intel Certified Solution Program

tech.ed 2009 Day2. Resul Pookutty's Key note session

Resul Pookutty's Key note session mesmerized everyone there. He is so impressive that session just got extended on and on.

He is so well prepared and organized with content. It is really unique of its kind.

Following is one of the clipping that were played at session. This one is from Oscar winning SDM.

MS-Tech Ed India 2009, Theme Song

Download it here.

Wednesday, May 13, 2009

Microsoft tech.ed 2009 Day1

Exciting first day. We shared pre-registration counter with Infosys.

Unfortunately our ID cards were not printed and thus we had to wait for sometime before we could go in.

Overall administration is not very much appreciable rather I would say they could have lot better.

Steve Ballmer keynote is really a highlight for this event.

I was on twitter through out sessions. 

Here are list of session I attended today
.Net 4.0 Fundamentals - Sanjay Vyas
ASP.Net MVC - Stephen Walther
Best Practices for team based S/W Developmen - Prashant G, Infosys
Architecting & Developing cool apps in this era of Multicore - Rajagopal, Intel

Couple of videos from session. I am sorry for bad quality. 

And I met two of my old colleagues Siddheshwar and Sreejumon at session. Expecting more fun tomorrow. 

TechEd 2009 - Hyderabad

Attending TechEd 2009 - Hyderabad from 13th to 15th May.

Expecting great sessions. Will post updates.

Friday, May 08, 2009

icloud has launched

Xcerion XML internet OS/3. I posted this when I got beta my beta account. It is released last month.

icloud is a service based on the Xcerion Internet Operating System /3 (XIOS/3).

XIOS is the technical solution behind the service. It offers “A free online computer with desktop, applications and storage.”

icloud consists of a desktop with applications and files that you run through your web browser. Because it's running in the cloud (the internet) it can offer you impressive features such as easy sharing and rich collaboration.

Some of the feature include

  • Online storage
  • Productivity
  • Photos, music, videos
  • Internet
  • Application development
  • Utility applications

    It is available in three forms. Check this link. Also check link for applications made available by default.

    Thursday, May 07, 2009

    Cascading DropDownLists in DetailsView – Databinding error

    I came across a requirement to have linked DropdownLists in insert mode of  DetailsView bound to EntityDataSource.

    In insert mode of DetailsView one of the fields is bound to a dropdownlist’s selected value.  But the requirement here is values of dropdownlist vary depending on where condition bound to selected value of another dropdown list.


    As shown above TaskID is one of the fields. But tasks vary based on project selected. This is achieved by converting TaskField to TemplateField. I have pasted below code for EditTemplate, InsertTemplate and ItemTempalte. In this only TaskID is bound column while project is added manually.

    Without doing modifications shown below I was getting error

    Databinding methods such as Eval(), XPath(), and Bind() can only be used in the context of a databound control.

    This is because upon postback DetailsView control is not re binding to selected value  SelectedValue='<%# Bind("TaskID") %>'

    <asp:TemplateField HeaderText="TaskID" SortExpression="TaskID">

    asp:Label ID="Label3" runat="server" Text='<%# Eval("TaskID") %>'></asp:Label>

    asp:DropDownList ID="DropDownList5" runat="server" AutoPostBack="True"
    DataSourceID="EntityDataSource5" DataTextField="ProjectName"
    DataValueField="ProjectID" Width="100%">
    asp:EntityDataSource ID="EntityDataSource5" runat="server"
    ConnectionString="name=MyEntities" include="Tasks"
    DefaultContainerName="MyEntities" EntitySetName="Projects">
    br />
    asp:DropDownList ID="DropDownList4" runat="server"
    DataSourceID="EntityDataSource6" DataTextField="TaskDescription"
    DataValueField="TaskID" Width="100%">
    asp:EntityDataSource ID="EntityDataSource6" runat="server"
    DefaultContainerName="MyEntities" EntitySetName="Tasks"
    Where="it.ProjectID==@ProjectID" >
    asp:ControlParameter ControlID="DropDownList5" Name
    Type="Int32" PropertyName
    ="SelectedValue" />

    asp:Label ID="Label3" runat="server" Text='<%# Bind("TaskID") %>'></asp:Label>


    Also observe highlighted portions where autopostback is set for project dropdownlist and its selectedvalue is bound to DetailsView in where condition of Tasks Dropdownlist. But here TaskID selected value is not bound to TaskID field of DetailsView.

    This binding is made in OnItemInserting event handler of DetailsView as shown below

    <asp:DetailsView ID="DetailsView1" runat="server" AutoGenerateRows="False" CellPadding="4"
    DataKeyNames="ResourceID" DataSourceID="EntityDataSource2" ForeColor="#333333"
    GridLines="None" Height="50px" Width="125px" OnItemInserted="DetailsView1_ItemInserted"
    DefaultMode="Insert" OnItemInserting="DetailsView1_OnItemInserting">

    with page behind file containing handler like

    protected void DetailsView1_OnItemInserting(object sender, DetailsViewInsertEventArgs e)
    String TaskID = ((DropDownList)(DetailsView1.FindControl("DropDownList4"))).SelectedValue;
    e.Values.Add("TaskID", TaskID);

    Here inserting event is handled to add TaskID field to values based on selected value of TaskID’s DropDownlist.

    Primary and Unique keys

    Today one of my colleagues expressed difficulty in ensuring uniqueness for certain columns in a table.

    Characteristics of these columns are

    1. There are not necessary (allow-null) columns for inserting a row in a table in which they are defined
    2. But when inserted they must form a unique combination

    What could have been done so easily with Unique Key became so difficult because of lack of referential integrity.

    These columns could have been defined in a different table and referenced with a foreign  key relationship to primary table.

    Such a simple thing could not be corrected as we are so tightly coupled with its structure. Awful! a classic example of making life miserable by knowingly living with self made mistakes.

    Tuesday, May 05, 2009

    Built-in functions of Transact-SQL

    Many a times, we end up spending lot of time doing something that made available to us just due to lack of awareness.

    Today I spent 30 minutes to get date as string from datetime column in database. Doing this from code is quite a trivial task.

    But here I want to bind a source to UI control. DATENAME function solved my problem just like that. It is built-in function of SQL.

    Here are some more references for built-in functions from MSDN

    Functions (Transact-SQL)

    Monday, May 04, 2009

    Wild west stunt show in Ramoji Film City

    Ramoji Film City, the largest film studio complex in the world as certified by Guinness World Records, is an ultimate leisure destination for holidays in Hyderabad. Following photograph taken before the start of the show. It is just a part of complete set.

    This particular show is so realistic and really makes you watch again and again.


    MSDN for low bandwidth

    Low bandwidth option of MSDN is really worth giving a try. Its much better than regular one.

    Find some of the low bandwidth options for MSDN.

    Low bandwidth

    This option is really good.



    Not quite there. Option to choose language is desired.



    Familiar one. But not so inviting


    MSDN Inside the (IDE)

    Useful, though can’t understand why feedback banner hides content at top. MSDN folks to correct this.

    Friday, May 01, 2009

    Using Set operations (SQL) to detect differences between two tables

    Identifying differences between two tables can become quite a daunting task.

    Using SQL set operations like {UNION,INTERSECT,EXCEPT} can greatly simply this is process.

    Any attempt to use compare operations on .Net runtime turns out to be very costly affair for these operations.


    I tried creating a set operations. Here my intention is to pass two tables which share same schema, then pass on ID field which

    is anchor. This results a single table specifying Addedd/Changed/Deleted/UnChanged records. That makes whole set.

    SELECT t1.*, 'Added'FROMTable1 t1
    LEFT JOINTable2 t2 ONt1.ID = t2.ID


    FROMTable1 t1
    INNER JOINTable2 t2 ONt1.ID = t2.ID
    FROMTable1 t1
    INNER JOINTable2 t2 ONt1.ID = t2.ID


    t2.*, 'Deleted'
    FROMTable1 t1
    RIGHT JOINTable2 t2 ONt1.ID = t2.ID


    FROMTable1 t1
    INNER JOINTable2 t2 ONt1.ID = t2.ID
    FROMTable1 t1
    INNER JOINTable2 t2 ONt1.ID = t2.ID


    I tried this with two tables each having 100 columns and 5000 rows. I could detect above mentioned changes like Added/Changed/Deleted/UnChanged within 18 seconds.

    Thus I believe set operations can offer much cleaner and simpler solution in such scenarios.