UiPath | Filter DataTable using LINQ Query | Handle Exception The source contains no DataRows

  Рет қаралды 42,980

Act Automate

Act Automate

Күн бұрын

Пікірлер: 85
@ActAutomate
@ActAutomate 2 жыл бұрын
📝 𝗟𝗜𝗡𝗤 𝗩𝗶𝗱𝗲𝗼𝘀 𝗔. 𝗣𝗔𝗥𝗧𝗜𝗧𝗜𝗢𝗡 𝗢𝗣𝗘𝗥𝗔𝗧𝗢𝗥𝗦 ➊ 𝗧𝗔𝗞𝗘: kzbin.info/www/bejne/hp_Eqp-BaJyagqc ➋ 𝗦𝗞𝗜𝗣: kzbin.info/www/bejne/iHW0anaoqdqggbc ➌ 𝗧𝗔𝗞𝗘𝗪𝗛𝗜𝗟𝗘: kzbin.info/www/bejne/pH6ZoIx8gbKdnLc ➍ 𝗦𝗞𝗜𝗣𝗪𝗛𝗜𝗟𝗘: kzbin.info/www/bejne/qX62fqB_fLSmq7M 𝗕. 𝗣𝗥𝗢𝗝𝗘𝗖𝗧𝗜𝗢𝗡 𝗢𝗣𝗘𝗥𝗔𝗧𝗢𝗥𝗦 ➊ 𝗦𝗘𝗟𝗘𝗖𝗧: kzbin.info/www/bejne/enrbYYaph7J_b9E ➋ 𝗦𝗘𝗟𝗘𝗖𝗧𝗠𝗔𝗡𝗬: kzbin.info/www/bejne/nKCceHdsp7l9iqM 𝗖. 𝗙𝗜𝗟𝗧𝗘𝗥𝗜𝗡𝗚 𝗢𝗣𝗘𝗥𝗔𝗧𝗢𝗥𝗦 ➊ 𝗪𝗛𝗘𝗥𝗘: kzbin.info/www/bejne/b2jFfmqZlL9mmZY 𝗗. 𝗤𝗨𝗔𝗡𝗧𝗜𝗙𝗜𝗘𝗥 𝗢𝗣𝗘𝗥𝗔𝗧𝗢𝗥𝗦 ➊ 𝗔𝗟𝗟: kzbin.info/www/bejne/rJCrk6SZlsqcqqs ➋ 𝗔𝗡𝗬: kzbin.info/www/bejne/q6TLfKaAdr2Fipo 𝗘. 𝗘𝗟𝗘𝗠𝗘𝗡𝗧 𝗢𝗣𝗘𝗥𝗔𝗧𝗢𝗥𝗦 ➊ 𝗘𝗹𝗲𝗺𝗲𝗻𝘁𝗔𝘁: kzbin.info/www/bejne/f6nTd2qiZtt2jsk ➋ 𝗘𝗹𝗲𝗺𝗲𝗻𝘁𝗔𝘁𝗢𝗿𝗗𝗲𝗳𝗮𝘂𝗹𝘁: kzbin.info/www/bejne/f6nTd2qiZtt2jsk ➌ 𝗙𝗶𝗿𝘀𝘁: kzbin.info/www/bejne/gJKQapd8etFpoNU ➍ 𝗙𝗶𝗿𝘀𝘁𝗢𝗿𝗗𝗲𝗳𝗮𝘂𝗹𝘁: kzbin.info/www/bejne/gJKQapd8etFpoNU ➎ 𝗟𝗮𝘀𝘁: kzbin.info/www/bejne/Y2awgmasnruhj5I ➏ 𝗟𝗮𝘀𝘁𝗢𝗿𝗗𝗲𝗳𝗮𝘂𝗹𝘁: kzbin.info/www/bejne/Y2awgmasnruhj5I
@psrivasavi
@psrivasavi 2 жыл бұрын
The BEST channel to learn LINQ use cases for UiPath. Very well explained. Thank you "UiPath - Mahmoud TV"!!
@ActAutomate
@ActAutomate 2 жыл бұрын
Thanks alot Sri Vasavi, happy to hear that :)
@saiprasadkakumanu521
@saiprasadkakumanu521 Жыл бұрын
@@ActAutomate Hi i have following Text in a Notepad: This is Jim Jim is teaching VBScript Jim will also teach UiPath Jim will travel i need count of word Occurances say word called "This" has occurred only once so "This -1", word called Jim occurred 4 times so "Jim -4" like that whatever text i keep i need count of each word i tried with this - its somewhat working - array_Tst.GroupBy(function (x) x.ToUpper).ToDictionary(function (x) x.Key, function (x) x.Count) but i copied the syntx from google which i did not understand so checking any other wya we can do it.. pls help
@skmNas
@skmNas 8 ай бұрын
You explain each topic so well like from a basic to an advance level, Please do continue the UiPath API Automation Series and also advanced topics of UiPath. Looking forward for more videos and more Knowledge gain from you. Thank you for the LINQ topics.
@ActAutomate
@ActAutomate 8 ай бұрын
Thanks for your feedback, really happy to hear that :-)
@ricardoguzman8328
@ricardoguzman8328 2 жыл бұрын
Easily on my top 3 LINQ tutorials online. Thanks a lot!
@ActAutomate
@ActAutomate 2 жыл бұрын
Very happy to hear that 🔥
@aparnapopade5066
@aparnapopade5066 Жыл бұрын
Got detailed Understanding of Linq!!Thank You!!
@ActAutomate
@ActAutomate Жыл бұрын
You're welcome Aparna :-)
@eventosLoucos
@eventosLoucos 2 жыл бұрын
You are awesome!😃
@ActAutomate
@ActAutomate 2 жыл бұрын
Thanks a lot Jessé 😃
@igornosenko171
@igornosenko171 Жыл бұрын
You have a perfect video series about LINQ, thanks a lot. But California and Texas are not the cities :)
@ActAutomate
@ActAutomate Жыл бұрын
Thanks for info. I didn't think about that, just wrote some names (Cities or States) :-)
@rasipogulabhaskar9858
@rasipogulabhaskar9858 Жыл бұрын
fantastic, superb... if you start class tell me am interested
@ActAutomate
@ActAutomate Жыл бұрын
Sure, it will be in the next months during this year, still not sure when exactly, but I will tell you that here on KZbin and LinkedIn ;-)
@rasipogulabhaskar9858
@rasipogulabhaskar9858 Жыл бұрын
@@ActAutomate simply your teaching skills and way of explanation amazing.. i need UI path...
@ActAutomate
@ActAutomate Жыл бұрын
@@rasipogulabhaskar9858 It will be about UiPath in general, and about LINQ in details
@ActAutomate
@ActAutomate Жыл бұрын
@@rasipogulabhaskar9858 Thanks ☺
@saiprasadkakumanu521
@saiprasadkakumanu521 Жыл бұрын
Hi i have following Text in a Notepad: This is Jim Jim is teaching VBScript Jim will also teach UiPath Jim will travel i need count of word Occurances say word called "This" has occurred only once so "This -1", word called Jim occurred 4 times so "Jim -4" like that whatever text i keep i need count of each word i tried with this - its somewhat working - array_Tst.GroupBy(function (x) x.ToUpper).ToDictionary(function (x) x.Key, function (x) x.Count) but i copied the syntx from google which i did not understand so checking any other wya we can do it.. pls help
@ActAutomate
@ActAutomate Жыл бұрын
You need to do the following: First you have to define the words as whole words. Each word will be with an empty space after it, or with a point, comma, new line, etc. Then you can write the query you have. It should work. At the end you can either print out the result of write it to a text file or something else. Here is the complete code: ' Normalize and split the text into words Dim words = text.Split(New Char() {" "c, vbCr, vbLf, vbTab, ","c, "."c, ";"c, ":"c, "!"c, "?"c}, StringSplitOptions.RemoveEmptyEntries) ' Use LINQ to group and count the words Dim wordCounts = words _ .GroupBy(Function(w) w.ToUpperInvariant()) _ .ToDictionary(Function(g) g.Key, Function(g) g.Count()) ' Iterate through the dictionary and print out each word and its count For Each wordCount In wordCounts Console.WriteLine("{0} - {1}", wordCount.Key, wordCount.Value) Next In case you only copy the code and it doesn't work, then you have to do the following: Under Imports tab (next to Variables, Arguments) import the following namespaces: System.LINQ System.Collections.Generic System.XML.LINQ Or to make it easier: Just write the code (DON'T COPY). Once you write the code, the needed imports will be added to your workflow automatically. Please let my know if you still need help!☺
@wingcheunghung6646
@wingcheunghung6646 2 жыл бұрын
Very useful video on linq, thx a lot !
@ActAutomate
@ActAutomate 2 жыл бұрын
You're welcome :-)
@f-alzahraa_Ahmed
@f-alzahraa_Ahmed Жыл бұрын
real thanks dude🙏🙏🤞🤞
@ActAutomate
@ActAutomate Жыл бұрын
you're welcome Fatima :-)
@preetikarauthan9096
@preetikarauthan9096 Жыл бұрын
Hello act automate, Really liked your videos on linq ..amazing explanation given . Can u please create a video on how to sort any integer array asc or desc. Thankyou!
@ActAutomate
@ActAutomate Жыл бұрын
Please check the following videos: kzbin.info/www/bejne/jIjFdmmXqctsjZo kzbin.info/www/bejne/jmm0qK2rgMhmftk kzbin.info/www/bejne/ppm0d6qQhptjbq8 These are about Order and Then methods, which can be used to sort in ascending and descending. If you still have any question, please write me back.
@DrzymalaWagon
@DrzymalaWagon 2 жыл бұрын
When it comes to that no data Ross exception i prefer to assign query results to a variable of Ienumerable of datarow and then checking its content with .Any methods, if it is true i then use .copytodatatable methods on that Ienumerable variable.
@ActAutomate
@ActAutomate 2 жыл бұрын
Thanks Drzymala for the info. As mentioned there are different ways to handle this exception and I prefer to use Try Catch. But if many are interested to learn how to handle the exception in different ways, I could create a video about that! Just let me know ;-)
@ankitmehta54
@ankitmehta54 2 жыл бұрын
@@ActAutomate Hi, Please Create More Videos For The Same.
@ActAutomate
@ActAutomate 2 жыл бұрын
@@ankitmehta54 I will do that in the video: LINQ - ANY Function Just wait for it ;-)
@aparnakrishnan5465
@aparnakrishnan5465 2 жыл бұрын
Thank you Sir. Very nice teaching ☺️.
@ActAutomate
@ActAutomate 2 жыл бұрын
Any time Aparna :-)
@samtej3130
@samtej3130 2 жыл бұрын
If Possible, can u suggest me the best resource for learning Linq queries from A to Z.
@ActAutomate
@ActAutomate 2 жыл бұрын
Unfortunately I don't know any source for that. There are many websites for LINQ, but I don't know which is the best one or where you can find everything, especially about LINQ in UiPath. Maybe you can search for a course on Udemy or LinkedIn I will also Create a full course about LINQ on Udemy using VB and C# with some material etc. where you can learn LINQ from A to Z For now you can check the videos on my channel. There are many videos about LINQ.
@samtej3130
@samtej3130 2 жыл бұрын
If possible please teach us lamda function and more complex problem solving skills using linq like how to filter multiple columns in a single dataset and their Approaches like Array to list etc . mean while please teach us most complex real time senario based dataset manipulations.
@samtej3130
@samtej3130 2 жыл бұрын
Since u already demonstrated filtering multiple columns ,please ignore from above line.
@ActAutomate
@ActAutomate 2 жыл бұрын
I will try to do that Sam. If you have specific examples, please let me know!
@Gilgameshx
@Gilgameshx Жыл бұрын
Is that vb or C#?
@ActAutomate
@ActAutomate Жыл бұрын
It's VB
@Gilgameshx
@Gilgameshx Жыл бұрын
@@ActAutomate oh I see, do you have any video in C#?
@ActAutomate
@ActAutomate Жыл бұрын
@@Gilgameshx Unfortunately not at the moment. Currently I am only posting about Linq using VB. Later I will do the same using C# For now you can use any online converter to convert the code from VB to C# For example this one: converter.telerik.com/
@Gilgameshx
@Gilgameshx Жыл бұрын
@@ActAutomate awesome!
@abdelrahmanbadr2404
@abdelrahmanbadr2404 2 жыл бұрын
19:08 "we need to use CStr method to converst the conent to string" why ? you was already using row(Country).ToString ?! .. what is the difference between CStr and ToString and why did you use both of them ?
@ActAutomate
@ActAutomate 2 жыл бұрын
Ah sorry, I used the both, but you only need one of them in this case, because you want to convert to string. So you either use: Where row("Country").ToString.IsNumeric or: Where CStr(row("Country")).IsNumeric But if you want to convert to another data type, you have to use .ToString, and also the function at the beginning. I mean if you want to convert to Integer, you use the following: CInt(row("Country").ToString) ToDouble: CDbl(row("Country").ToString) So you need to get the content of the row as string using .ToString Then you convert to integer for example using CInt But as mentioned, if you want to convert to string, then only once is enough, either .ToString or CStr Both functions have the same result, no difference between the both! Thanks for the comment and the hint :-)
@abdelrahmanbadr2404
@abdelrahmanbadr2404 2 жыл бұрын
@@ActAutomate now i get it , thanks for explaining , Keep up the good work!
@ActAutomate
@ActAutomate 2 жыл бұрын
@@abdelrahmanbadr2404 You're welcome Abdelrahman. We are happy that you are active in the channel and ask very useful questions. Kepp up also the good questions and share the knowledge with your friends. Great to have you here :)
@abdelrahmanbadr2404
@abdelrahmanbadr2404 2 жыл бұрын
@@ActAutomate that's very kind of you :)
@LuisFernando-ux1ys
@LuisFernando-ux1ys 2 жыл бұрын
Hello Act Automate! Today I come with a different question. How can I get de Last row index of a specific columnn in a Data Table? I have a data table which every column is completely independent from each other. which means that a column might have info till the row 9 where another column in the same dt has info till the row 4. Let me know if you understood my question. Thank you vey much once again.
@ActAutomate
@ActAutomate 2 жыл бұрын
Hi Luis, I am happy to hear your questions, which give me new ideas for new videos! So I understood your question so: You have a datatable, which contains different columns and rows. Each row could have a content in each column, but it could be also empty in some columns. You want to get the last row index, where a specific column is filled it. For example, the table contains 10 rows, and 3 columns. The second column contains content in some rows only, and the last filled one is the 5th one. You want to get the index of this 5th row. Is it correct? You can also add some examples here, so that I can understand you better, and it's also good for the others, who could have the same question, so that they understand it and could use it in their projects!
@LuisFernando-ux1ys
@LuisFernando-ux1ys 2 жыл бұрын
Forget it, it's just a simple linq query!!! Already solve it
@LuisFernando-ux1ys
@LuisFernando-ux1ys 2 жыл бұрын
@@ActAutomate Yes is correct, What i actually did is this = Numero_Fila = ( From row In dt_CostosGastos Where row(in_TipoGasto) IsNot Nothing Select row ).Select(Function(x) dt_CostosGastos.Rows.IndexOf(x)).ElementAtOrDefault(0) I was hoping to get the first empty row of the columnn name that is saved in "in_TipoGasto" but it always gives me 0 as result. What am I doing wrong?
@ActAutomate
@ActAutomate 2 жыл бұрын
@@LuisFernando-ux1ys Very good!
@ActAutomate
@ActAutomate 2 жыл бұрын
@@LuisFernando-ux1ys You want to get the first empty row using a column, or to get the first filled row, or to get the last filled? To make your query better, I recommend you to use the following function before ElementAtOrDefault operator: DefaultIfEmpty(-1).ElementAtOrDefault(0) In this way, if you don't have an index, you will get -1 as result. In this way you can differentiate between row index 0 and nothing (0) --> now it's -1
@rpateam8623
@rpateam8623 2 жыл бұрын
Hi.. Nice Video.. i want know compare the two datatable.. can expalin tolist, to array, etc... to copydatatable..in the possible way...
@ActAutomate
@ActAutomate 2 жыл бұрын
Sorry I didn't understand the question. Can you please explain more what you want to learn?!
@rpateam8623
@rpateam8623 2 жыл бұрын
@@ActAutomate Linq is Powerful tool to access data from different sources and methods. To get data requirement details. So that I want to know more about linq can you explain all operators in linq? Aggregation --Aggregate, Average, Count, LongCount, Max, Min, Sum Conversion --AsEnumerable, Cast, OfType, ToArray, ToDictionary, ToList, ToLookup Element--ElementAt, ElementAtOrDefault, First, FirstOrDefault, Last, LastOrDefault, Single, SingleOrDefault Generation --DefaultIfEmpty, Empty, Range, Repeat Grouping --GroupBy Join --Group Join, Join Ordering --Order By, OrderByDescending, Reverse, ThenBy, ThenByDescending Other --Concat, SequenceEqual, Zip Partitioning --Skip, SkipWhile, Take, TakeWhile Projection --Select, SelectMany Quantifiers -All, Any, Contains Restriction --Where Set--Distinct, Except, Intersect, Union etc., You are using single data Table only, can you tell how to use more than one data table in linq. Can you explain all sequence above topics as soon as possible...? Because we are waiting for more than a month for this query… Note: No Coding Knowledge person also learns this query in easy way… By Pragash
@ActAutomate
@ActAutomate 2 жыл бұрын
@@rpateam8623 Hi Pargash, All these topics are already on our ToDo list. I will explain all these topics in the next time. Just let me finish ReFramework Videos, then we can only post videos about LINQ. We need some help so that we can continue posting new videos, therefore we don't post more than one video pro week currently. There is no big audience etc. Please share channel with you friends and help us to improve our channel!
@nalayathan123
@nalayathan123 2 жыл бұрын
Hi your way of teaching very nice.. Can you upload c# tutorials easy way.. If I become rpa developer should I learn c# right.. Atleast logic building purpose need c#.. Please if possible can you upload c#
@ActAutomate
@ActAutomate 2 жыл бұрын
Thanks for commenting Thayalan :) Using C# you can do mostly everything. I need more specific need, what you want to learn exactly? For example rename excel sheet using C#, then I can explain it to you, etc.
@nalayathan123
@nalayathan123 2 жыл бұрын
@@ActAutomate I want learn c# Tutorials beginer to medium level.. If u have video or let me best sites
@balramraviks
@balramraviks Жыл бұрын
Hi bro, could u pls create a video on linq query updating the row value of one column with value if the another column row matches the value. Example "column1" which contains the value "Paper" then update "Column3" = "Scissors"
@ActAutomate
@ActAutomate Жыл бұрын
Sure I will do that, but it will be later, after explaning the methods. It's also not easy to do like other use cases.
@balramraviks
@balramraviks Жыл бұрын
@@ActAutomate thks bro appreciate your reply
@ActAutomate
@ActAutomate Жыл бұрын
☺@@balramraviks
@mohanvasan2629
@mohanvasan2629 Жыл бұрын
This is good but could you explain this, on the example 8 where we look each column, If each column is looping and creating additional rows why it is not creating additional rows at the place where we have column value in the rows where we have also found empty, While empty is being ignored the other values should also create an additional row right, Could you explain that by the way tried this one after completing all your Linq videos, ( From Row In dtInput.Rows.Cast(Of System.Data.DataRow) Where Not Row.ItemArray.Any(Function(x) String.IsNullOrEmpty(x.Tostring.Trim)) Select Row ).CopyToDataTable
@ActAutomate
@ActAutomate Жыл бұрын
I didn't get your point. Do you want me to explain the example number 8 or your query? What is the question exactly? What do you want to understand? Please give me more details with examples or with the part of the code you are talking about.
@girishkrishna4654
@girishkrishna4654 Жыл бұрын
18:11 Mahmoud, this code giving me compiling error.
@ZidanMhmd
@ZidanMhmd Жыл бұрын
Did you get the answersll? I didn't get that too
@girishkrishna4654
@girishkrishna4654 Жыл бұрын
@@ZidanMhmd use the following code. ( From row In dt_Input From col In dt_Input.Columns.Cast(Of DataColumn) Where Not String.IsNullOrEmpty(row(col).ToString) Select row ).Distinct.CopyToDataTable
@ActAutomate
@ActAutomate Жыл бұрын
Thanks for the answer. This is correct. I just wrote the expression wrong. Normally we should use it always in this way: String.IsNullOrEmpty(YourStringVariable) Not String.IsNullOrEmpty(YourStringVariable) and so on The other one causes errors in case of DBNull etc.
@khaledbinjameel9639
@khaledbinjameel9639 2 ай бұрын
I'm having that error too
@rikkyjoshy
@rikkyjoshy 2 жыл бұрын
nice
@ActAutomate
@ActAutomate 2 жыл бұрын
Thanks Rikky :)
@ketanwajekar2547
@ketanwajekar2547 2 жыл бұрын
C# advance code use in Uipath
@ActAutomate
@ActAutomate 2 жыл бұрын
Ketan, Sorry, I didn't get your point. Do you want the same in C# or do you mean something else?
@fwziayasser4510
@fwziayasser4510 2 жыл бұрын
🔥🔥🔥
@ActAutomate
@ActAutomate 2 жыл бұрын
💥💥💥
@anilsingh-rd2fm
@anilsingh-rd2fm Жыл бұрын
0:34
@ActAutomate
@ActAutomate Жыл бұрын
Do you want to say something?!
@SenthilKumar-ue8pr
@SenthilKumar-ue8pr 2 жыл бұрын
Hi , (From row In Linq Where row("ACTIVITY").ToString.contains("PV","DF","DD") Select row).CopyToDatatable how to implement multiple values
@ActAutomate
@ActAutomate 2 жыл бұрын
You mean, you want to check, if the row contains any value from these three values ? You only have to change to Where Statement . Where row("ACTIVITY").ToString.Contains("PV") OrElse row("ACTIVITY").ToString.Contains("DF") OrElse row("ACTIVITY").ToString.Contains("DD")
She made herself an ear of corn from his marmalade candies🌽🌽🌽
00:38
Valja & Maxim Family
Рет қаралды 18 МЛН
Quilt Challenge, No Skills, Just Luck#Funnyfamily #Partygames #Funny
00:32
Family Games Media
Рет қаралды 55 МЛН
We Attempted The Impossible 😱
00:54
Topper Guild
Рет қаралды 56 МЛН
小丑女COCO的审判。#天使 #小丑 #超人不会飞
00:53
超人不会飞
Рет қаралды 16 МЛН
Next level FILTER Function tricks | Excel Off The Grid
13:23
Excel Off The Grid
Рет қаралды 42 М.
Q&A LINQ Querries | UiPath Automation Developer Professional Exam Preparation
15:34
5 Excel Secrets You'll Be Embarrassed You Didn't Know
17:32
Excel Campus - Jon
Рет қаралды 297 М.
Master Grouping Columns in UiPath using LINQ
27:40
Automate with Rakesh
Рет қаралды 4,1 М.
Solving one of PostgreSQL's biggest weaknesses.
17:12
Dreams of Code
Рет қаралды 228 М.
Learn SQL In 60 Minutes
56:24
Web Dev Simplified
Рет қаралды 2,2 МЛН
She made herself an ear of corn from his marmalade candies🌽🌽🌽
00:38
Valja & Maxim Family
Рет қаралды 18 МЛН