Join Olivia Chiu Stone for an in-depth discussion in this video Select a data source, part of LINQ with C# Essential Training.
- Every LINQ query has three parts to its basic structure.…LINQ query begins with a data source.…The data source consists of a sequence of elements.…The sequence needs to be something…that can be iterated over using a foreach statement…such as an array or a list.…The elements in the sequence…can be of any type of data.…So an array of integers,…or a series of characters,…or a list of objects can all be…the data source for a LINQ query.…This is a declaration for query called state query.…
I'll go into detail about the type of state query later.…For now, I'll focus on the LINQ query specification.…The from clause is used to introduce the data source…or sequence to use in the query.…In this example, the data source is a list…of customer objects representing…the customers for a company.…Cust acts as a range variable.…This is similar to the interation variable…in a foreach statement.…However, in this case, the sequence will not be…iterated over at this point in the program.…When the query executes,…the range variable will be used to…
AuthorOlivia Chiu Stone
In LINQ with C# Essential Training, engineer Olivia Chiu introduces techniques for querying, updating, and transforming data with LINQ. She covers standard queries—such as finding overlaps in two datasets and creating hierarchies—as well as complex chained queries. She also shows how to group and join LINQ queries with lambda expressions, and use LINQ to query SQL databases and XML documents. Last but not least, Olivia provides tips for optimizing the performance of your queries.
- Creating and executing a LINQ query
- Returning results
- Changing the data source type
- Performing standard queries
- Working with lambda expressions
- Chaining and complex queries
- Querying SQL and XML
- Performing tree queries
- Using sequences, elements, and scalars
- Allocating memory
Skill Level Intermediate
1. Introduction to LINQ
Common use cases1m 45s
2. Basic LINQ Queries
3. Data Transformation
Return results as a new type1m 39s
4. Type Relationships
5. Standard Queries
6. Lambda Expressions
7. Complex Queries
8. LINQ to SQL
9. LINQ to XML
10. Other Operators
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.