LINQ queries demonstrate how to operate and query the Google Analytics objects wrapped in an Entity Framework data model. Listed below are some examples of LINQ queries supported by the Entity framework.
Select and Filter Retrieve records from the Traffic table where the Country is "Japan". |
| ||||
Contains
Retrieve records from the Goals table where the Name property contains the substring "xamarin". |
| ||||
Limit
Retrieve the first 10 records from the Goals table. |
| ||||
Order by
Retrieve all records from the Goals table and sort them in descending order based on the Name property. |
| ||||
Count
Count all entities that match a given criterion. |
| ||||
Group by
Group records from the Goals table based on the Value property. The groups are then ordered in descending order based on the Value. |
| ||||
Joins
Cross-join between the Goals and Traffic tables. |
|