Skip to content

Commit 1ce088a

Browse files
add common data sources note in 'Standard query operators' section (#47928)
* add common-data-sources-reference note * add new note to each 'Standard query operators' article * update common-data-sources-reference.md
1 parent f7ae46e commit 1ce088a

File tree

10 files changed

+27
-0
lines changed

10 files changed

+27
-0
lines changed
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
---
2+
author: ''
3+
ms.author: ''
4+
ms.topic: include
5+
ms.date: 08/11/2025
6+
---
7+
8+
> [!NOTE]
9+
> You can refer to the common data sources for this area in the [Standard Query Operators Overview](../standard-query-operators/index.md) article.

docs/csharp/linq/standard-query-operators/converting-data-types.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ The conversion methods in this table whose names start with "As" change the stat
3434

3535
[!INCLUDE [Datasources](../includes/data-sources-definition.md)]
3636

37+
[!INCLUDE [Common Datasources reference](../includes/common-data-sources-reference.md)]
38+
3739
## Query Expression Syntax Example
3840

3941
The following code example uses an explicitly typed range variable to cast a type to a subtype before accessing a member that is available only on the subtype.

docs/csharp/linq/standard-query-operators/filtering-data.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ The standard query operator methods that perform selection are listed in the fol
2222

2323
The following example uses the `where` clause to filter from an array those strings that have a specific length.
2424

25+
[!INCLUDE [Common Datasources reference](../includes/common-data-sources-reference.md)]
26+
2527
:::code language="csharp" source="./snippets/standard-query-operators/WhereFilter.cs" id="FilterExampleQuery":::
2628

2729
The equivalent query using method syntax is shown in the following code:

docs/csharp/linq/standard-query-operators/grouping-data.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ The equivalent query using method syntax is shown in the following code:
2828

2929
[!INCLUDE [Datasources](../includes/data-sources-definition.md)]
3030

31+
[!INCLUDE [Common Datasources reference](../includes/common-data-sources-reference.md)]
32+
3133
## Group query results
3234

3335
Grouping is one of the most powerful capabilities of LINQ. The following examples show how to group data in various ways:

docs/csharp/linq/standard-query-operators/join-operations.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@ The following illustration shows a conceptual view of two sets and the elements
2727

2828
[!INCLUDE [Datasources](../includes/data-sources-definition.md)]
2929

30+
[!INCLUDE [Common Datasources reference](../includes/common-data-sources-reference.md)]
31+
3032
The following example uses the `join … in … on … equals …` clause to join two sequences based on specific value:
3133

3234
:::code language="csharp" source="./snippets/standard-query-operators/JoinOverviewExamples.cs" id="JoinQuerySyntax":::

docs/csharp/linq/standard-query-operators/partitioning-data.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@ The standard query operator methods that partition sequences are listed in the f
2727

2828
All the following examples use <xref:System.Linq.Enumerable.Range(System.Int32,System.Int32)?displayProperty=nameWithType> to generate a sequence of numbers from 0 through 7.
2929

30+
[!INCLUDE [Common Datasources reference](../includes/common-data-sources-reference.md)]
31+
3032
You use the `Take` method to take only the first elements in a sequence:
3133

3234
:::code source="snippets/standard-query-operators/PartitionExamples.cs" id="Take":::

docs/csharp/linq/standard-query-operators/projection-operations.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ The standard query operator methods that perform projection are listed in the fo
2323

2424
The following example uses the `select` clause to project the first letter from each string in a list of strings.
2525

26+
[!INCLUDE [Common Datasources reference](../includes/common-data-sources-reference.md)]
27+
2628
:::code language="csharp" source="./snippets/standard-query-operators/SelectProjectionExamples.cs" id="SelectSimpleQuery":::
2729

2830
The equivalent query using method syntax is shown in the following code:

docs/csharp/linq/standard-query-operators/quantifier-operations.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ The following illustration depicts two different quantifier operations on two di
2424

2525
The following example uses the `All` to find students that scored above 70 on all exams.
2626

27+
[!INCLUDE [Common Datasources reference](../includes/common-data-sources-reference.md)]
28+
2729
:::code language="csharp" source="./snippets/standard-query-operators/QuantifierExamples.cs" id="AllQuantifier":::
2830

2931
## Any

docs/csharp/linq/standard-query-operators/set-operations.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ The following example depicts the behavior of <xref:System.Linq.Enumerable.Excep
3636

3737
[!INCLUDE [Datasources](../includes/data-sources-definition.md)]
3838

39+
[!INCLUDE [Common Datasources reference](../includes/common-data-sources-reference.md)]
40+
3941
:::code language="csharp" source="./snippets/standard-query-operators/SetOperations.cs" id="Except":::
4042

4143
The <xref:System.Linq.Enumerable.ExceptBy%2A> method is an alternative approach to `Except` that takes two sequences of possibly heterogenous types and a `keySelector`. The `keySelector` is the same type as the first collection's type. Consider the following `Teacher` array and teacher IDs to exclude. To find teachers in the first collection that aren't in the second collection, you can project the teacher's ID onto the second collection:

docs/csharp/linq/standard-query-operators/sorting-data.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@ The standard query operator methods that sort data are listed in the following s
2727

2828
[!INCLUDE [Datasources](../includes/data-sources-definition.md)]
2929

30+
[!INCLUDE [Common Datasources reference](../includes/common-data-sources-reference.md)]
31+
3032
## Primary Ascending Sort
3133

3234
The following example demonstrates how to use the `orderby` clause in a LINQ query to sort the array of teachers by family name, in ascending order.

0 commit comments

Comments
 (0)