# Live Views

## Content



Client views are live; they are kept automatically up-to-date with changing data. But live views functionality is more general, live views (objects of class [C1.LiveLinq.LiveViews.View](/componentone/api/win/online-datasource/dotnet-framework-api/C1.LiveLinq.4.8/C1.LiveLinq.LiveViews.View.html) from which **ClientView** is derived) can be defined on data of any kind, including but not limited to entities, and they support more LINQ query operators, such as grouping, sorting, joins and more (see ComponentOne LiveLinq).

All such operations (of which the most popular are grouping and sorting) can be applied to client views (because **ClientView** is derived from [View](/componentone/api/win/online-datasource/dotnet-framework-api/C1.LiveLinq.4.8/C1.LiveLinq.LiveViews.View.html)). For example:

```auto
View productsByCategory = products    .OrderBy(p => p.ProductName).GroupBy(p => p.CategoryID);
```

or in LINQ query syntax:

```auto
View productsByCategory =     from p in products 
    orderby p.ProductName     group p by p.CategoryID into g 
    select new { Category = g.Key, Products = g };
```

The resulting views are live, but they are not client views. This is not a defect of some sort; it is simply because such views don’t need [ClientView](/componentone/api/win/online-datasource/dotnet-framework-api/C1.Data.Entity.4.8/C1.Data.ClientView-1.html) functionality. Sorting and grouping can be performed entirely on the client without resorting to the server. However, developers must be aware of this fact to avoid confusion. Once you applied a LINQ query operation to your view, it becomes a [View](/componentone/api/win/online-datasource/dotnet-framework-api/C1.LiveLinq.4.8/C1.LiveLinq.LiveViews.View.html), not a **ClientView** (however, it remains live, automatically reflects all changes you make to the data on the client). So, for example, if you need server-side filtering, use the **AsFilter** method, not the LINQ _Where_ method. Use the LINQ _Where_ method when you want filtering on the client.