Added more nested optimizations in C# queries.
xml