I found the cause of this error that the web.config was referencing System.Web.WebPages.Razor, version=126.96.36.199. Later I changed it to System.Web.WebPages.Razor, version=188.8.131.52 it works fine problem was resolved.
We can retrieve data from URL to controller action method by two methods in asp.net mvc such as parameter of action method function and Query string. We can get Query string value just like web forms as Request.QueryString.
When I was trying to run the application I had faced this problem. I resolved by selecting the complete object that result will consists of complete customer objects. But before I selected a subset of the customer objects, just two members.