Saturday, September 13, 2008

This is Anfield!!!!


How long does it take to travel from Cloud nine to Earth? If you ask Sir Alex this question, his answer would be 90 minutes. Because that’s exactly what Man Utd. Went through on their trip to Liverpool. Rafa had a day to savour as he won his first victory against Manchester United 2-1.


 


The start was anything but uneventful. The starting line-ups were pre-cursors to what was to follow. No Gerrard; No Torres for Liverpool and Ferguson sent out a statement of “intent” by playing Berbatov in the starting line-up. For the first 20 minutes everything seemed to go United’s way. Berbatov was involved in the build up on the right hand side to what would eventually be a Carlos Tevez goal. Tevez had another chance when he had to net in a cross with Just Reina to beat but he couldn’t keep it down. Tevez and United eventually paid heavily for that miss because as it turned out Liverpool just arrived into the game late. When they did, they swept away the “Red Devils”. For the next 70 minutes only one team played.


 


There were the likes of Rooney, Tevez, Berbatov, Kuyt and Keane on the pitch but the irony was all the three goals were scored due to big defensive lapses. Javier Masceranho was the first culprit for not tracking Tevez’s run into the middle.Unmarked Tevez netted Berbatov’s cross in the 3rd minute to give United the lead. Most of Liverpool’s attacking was from the right, with Arbeloa and debutant Riera being impressive. In the 26th minute, Van Der Saar messed up a Liverpool cross to fumble the ball to Wes Brown’s feet resulting in an own goal. Liverpool were level. As hard as United tried, it wasn’t just their day. Carrick was making his comeback from an injury but that didn’t last long. He injured himself on a sliding tackle trying to win the ball back. A substitution was apparent and Liverpool were getting on top.


 


Second half continued to be more embarrassment for the visitors. Ryan Giggs came in for Carrick. It seemed as if the substitution would work when his long distance drive was on target making Reina stretch to keep it out. As it turned out that wouldn’t be Giggs most significant moment in the game. Liverpool were keeping up the pressure at the other end. Rafa brought in Gerrard and Babel to induce some pace into the Liverpool attack. In the 75th minute, Giggs, riding the baseline, instead of kicking the ball over for a corner, tried to keep it in play only for Liverpool to take possession. Kuyt’s cross met Babel’s legs resulting in the winner for Liverpool. But the trauma for United was far from over. A minute before full time, Vidic made an error in judgement hustling for a ball he was never in contention for. He was given a second yellow and a red. He will now miss his game against Chelsea.


 


The victory now leaves Liverpool top of the table but Chelsea can catch them when they play Manchester City later in the day. As for United, 4 points from the first 3 games is hardly the start they would have liked. They are not strangers to having slow starts and catching up during the latter half of the season, so don’t write them off just yet. But for their striker trio, I don’t think we will see Berbatov, Rooney and Tevez starting again for some time.

Thursday, September 11, 2008

Who's Who - I



  • Whose "About Me" reads "Okay, here goes: twenty-something, single, female, writer, with large groups of friends and who goes out for drinks pretty regularly. That's my life and that's what I write about. Okay? Okay."

  •  

  • X's company was taken away from him when he was 30. He resigned and founded his own company Y. One year after he was sacked, he acquired the company Z from W. Y was then bought out by his original company A. X is now the CEO of A. Identify all the variables.

  •  

  • He is the 5th genration descendant of the legendary warrior Sardar Hari Singh Nalwa. His parents are the promoters of Hitech Group of Companies. Identify this personality who is a household name now.

  •  

  • At the London Film Festival when Y was bowing accept the audience's appreciation, he was informed that a very important celebrity wanted to meet him backstage. Y was stunned to find Z waiting to hug him and congratulate him. Identify the two personalities in question here

  •  

  • Identify this person. A bonus for explaining what he is credited with.


  •  


     

     


     


     

     

    Tuesday, September 9, 2008

    ADO.NET Data Services Part - II

    In part – I of this series, we saw how we can perform GET operations over the web with ADO.NET Data Services. But any data model should also allow inserts, updates and deletes. In ADO.NET Data Services, you can do that by using the appropriate HTTP header and passing the corresponding values.


     


    Data Manipulation


     


    For eg. A simple insert with ADO.NET Data Services will look like below


     


                NorthwindEntities test = new NorthwindEntities(new Uri("http://localhost:6129/NorthwindDataService.svc"));


                Suppliers addSupp = new Suppliers();


                addSupp.CompanyName = "test supplier add from web client";


                test.AddToSuppliers(addSupp);


                test.SaveChanges();


     


    This in-turn sends a HTTP POST Request with the Supplier Name enclosed in the given format. In this case, the ATOM XML will look something like


     


     


     


     


     


     



    ATOM:


    <entry  xmlns:ads="http://schemas.microsoft.com/ado/2007/08/dataweb"   


            xmlns="http://www.w3.org/2005/Atom">


      <content type="application/xml">


        <ads:SupplierName> test supplier add from web client </ads:SupplierName>


      </content>


    </entry>


     


    You can similarly do Update and Delete Operations. For update, the HTTP header you would use is HTTP PUT and for Delete, it would be HTTP DELETE. You will hardly have to code the HTTP Headers yourself but it is always good to know.


     


    Advantages of ADO.NET Data Services


     


    There could be a lot of places where you could be thinking about using ADO.NET Data Services. There are a few that come to my mind right away


     


    1.       Support for AJAX based frameworks


     


    Use of the JSON format makes it much easier for silverlight based applications to get and manipulate records. Before ADO.NET Data Services, SILVERLIGHT applications had to use AJAX to manipulate the records. This way building RIA becomes a lot easier.


     


    2.       Enables use of HTTP Caching infrastructure


     


    Since ADO.NET uses REST it can use HTTP Caching infrastructure to make sure a lot of data is cached. Compare this with traditional services which are predominantly stateless. This way there is potential to reduce a lot of network traffic.


     


    3.       Underlying Data Source is completely encapsulated


     


    With ADO.NET Data Services in place, you can build your Data Access Layer which is independent of the underlying data storage technology. Suddenly you are not bothered about pooling connections, using the right providers. All you are worried about is whether you have access to the URI.


     


    4.       Separate Control Operations from queries\stored procedures


     


    Let me take an example. Suppose you wanted to write a stored procedure that gives you the list of the contacts in your application. Your user interface has a sort feature. To implement sort, you have two options viz. a) Get the data in a dataset and sort the records of the dataset or b) write two stored procedures that do sorting asc or desc. Now imagine this is the ADO.NET Data Services world. To sort or filter your records you don’t need to change your stored procedure all you need to change is the URl. That does make things simple isn’t it?


     


    That’s it for now. In Part –III we will actually be creating ADO.NET Data Services and using that from a client that we will build. So back in a week with the next part.