You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Modified the sample app to show how to limit the number of fields returned by the backend to improve fetching performance by limiting the amount of data transferred over the connection. Two methods are shown:
1. Define a FieldLayout in the XamDataPresenter with the subset of Fields that should be fetched
2. Set the ODataDataSource's new DesiredFields property to an array of strings that define the subset of schema fields that should be fetched.
<local:ODataSourceListItemBaseUri="http://services.odata.org/AdventureWorksV3/AdventureWorks.svc"EntitySet="CompanySales"Description="AdventureWorks Company Sales"/>
<local:ODataSourceListItemBaseUri="http://data.scottsdaleaz.gov/Planning/BuildingPermits.svc"EntitySet="BuildingPermits"Description="Scottsdale Building Permits"/>
93
-
<local:ODataSourceListItemBaseUri="http://data.scottsdaleaz.gov/Planning/BuildingPermits.svc"EntitySet="BuildingInspections"Description="Scottsdale Building Inspections"/>
94
-
<local:ODataSourceListItemBaseUri="http://data.scottsdaleaz.gov/MunicipalServices/CapitalImprovementProjects.svc"EntitySet="Projects"Description="Scottsdale Capital Improvement Projects"/>
95
-
<local:ODataSourceListItemBaseUri="http://data.scottsdaleaz.gov/Finance/BusinessLicenses.svc"EntitySet="BusinessLicenses"Description="Scottsdale Business Licenses"/>
<local:ODataSourceListItemBaseUri="http://odata.research.microsoft.com/odata.svc"EntitySet="Projects"Description="Microsoft Research - Projects"/>
99
-
<local:ODataSourceListItemBaseUri="http://odata.research.microsoft.com/odata.svc"EntitySet="Publications"Description="Microsoft Research - Publications"/>
<local:DataSourceConfigurationInfoBaseUri="http://services.odata.org/AdventureWorksV3/AdventureWorks.svc"EntitySet="CompanySales"Description="AdventureWorks Company Sales"/>
<local:DataSourceConfigurationInfoBaseUri="http://data.scottsdaleaz.gov/Planning/BuildingPermits.svc"EntitySet="BuildingPermits"Description="Scottsdale Building Permits">
93
+
<!-- Limit the amount of data fetched from this OData service by setting the DesiredFIelds property. Refer to
94
+
the cboOdataSources_SelectionChanged event handler code in MainWindow.xaml.cs to see how we apply these settings when
<local:DataSourceConfigurationInfoBaseUri="http://data.scottsdaleaz.gov/Planning/BuildingPermits.svc"EntitySet="BuildingInspections"Description="Scottsdale Building Inspections"/>
107
+
<local:DataSourceConfigurationInfoBaseUri="http://data.scottsdaleaz.gov/MunicipalServices/CapitalImprovementProjects.svc"EntitySet="Projects"Description="Scottsdale Capital Improvement Projects"/>
108
+
<local:DataSourceConfigurationInfoBaseUri="http://data.scottsdaleaz.gov/Finance/BusinessLicenses.svc"EntitySet="BusinessLicenses"Description="Scottsdale Business Licenses"/>
<local:DataSourceConfigurationInfoBaseUri="http://odata.research.microsoft.com/odata.svc"EntitySet="Projects"Description="Microsoft Research - Projects"/>
112
+
<local:DataSourceConfigurationInfoBaseUri="http://odata.research.microsoft.com/odata.svc"EntitySet="Publications"Description="Microsoft Research - Publications"/>
100
113
</ComboBox>
101
114
<CheckBoxx:Name="chkNullOutDatasource"IsChecked="True"Style="{StaticResource CheckBoxText}">Null out datasource before setting new</CheckBox>
0 commit comments