filmov
tv
Part 3 Querying xml document using linq to xml
![preview_player](https://i.ytimg.com/vi/Ii3QSkTiRA8/maxresdefault.jpg)
Показать описание
In Parts 1 and 2 of LINQ to XML tutorial, we discussed creating XML documents using LINQ to XML.
Text version of the video
Healthy diet is very important both for the body and mind. If you like Aarvi Kitchen recipes, please support by sharing, subscribing and liking our YouTube channel. Hope you can help.
Slides
LINQ to SQL Tutorial - All Text Articles & Slides
LINQ to XML Tutorial Playlist
Dot Net, SQL, Angular, JavaScript, jQuery and Bootstrap complete courses
In this video, we will discuss how to query xml document using linq to xml. We want to retrieve all the student names who has TotalMarks greater than 800. Students names should be sorted by TotalMarks in descending order.
where (int)student.Element("TotalMarks") ] 800
orderby (int)student.Element("TotalMarks") descending
select student.Element("Name").Value;
foreach (string name in names)
{
Console.WriteLine(name);
}
Alternate way of writing the above query.
where (int)student.Element("TotalMarks") ] 800
orderby (int)student.Element("TotalMarks") descending
select student.Element("Name").Value;
Text version of the video
Healthy diet is very important both for the body and mind. If you like Aarvi Kitchen recipes, please support by sharing, subscribing and liking our YouTube channel. Hope you can help.
Slides
LINQ to SQL Tutorial - All Text Articles & Slides
LINQ to XML Tutorial Playlist
Dot Net, SQL, Angular, JavaScript, jQuery and Bootstrap complete courses
In this video, we will discuss how to query xml document using linq to xml. We want to retrieve all the student names who has TotalMarks greater than 800. Students names should be sorted by TotalMarks in descending order.
where (int)student.Element("TotalMarks") ] 800
orderby (int)student.Element("TotalMarks") descending
select student.Element("Name").Value;
foreach (string name in names)
{
Console.WriteLine(name);
}
Alternate way of writing the above query.
where (int)student.Element("TotalMarks") ] 800
orderby (int)student.Element("TotalMarks") descending
select student.Element("Name").Value;
Комментарии