Тёмный

Row Number function in SQL Server 

kudvenkat
Подписаться 835 тыс.
Просмотров 240 тыс.
50% 1

Опубликовано:

 

3 окт 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 77   
@krzysztofs8535
@krzysztofs8535 7 лет назад
Row number rules ! And Venkat rules! You are the best teacher on youtube and in the whole world. I saw all your videos from SQL Server tutorial. Thank U for educating community! God bless you.
@piyako3586
@piyako3586 4 месяца назад
Tried so many videos on RU-vid after a few minutes I come out of it as I don't understand what they are talking about. You are the best:) Explained all concepts very clearly I found not just a good teacher but also a great soul :) Your voice is very soothing and pleasant on the ears wanting to listen more and more. God Bless you and Thanks once again
@tenziny9253
@tenziny9253 7 лет назад
GREAT TEACHER! I have been using your videos to reference SQL where I have no clues. Thanks for all your hard works!
@sayeedm6038
@sayeedm6038 2 года назад
Very well explained! Keep making such amazing tutorials!
@dawitworku821
@dawitworku821 5 месяцев назад
Very helpful as usual.
@MrHorzel
@MrHorzel 7 лет назад
Really well explained. Thank you. I really appreciate that you explained the use of it, more people should add that 'cause it's not always clear.
@Csharp-video-tutorialsBlogspot
You are very welcome and thank you very much for taking time to give feedback. This means a lot. I am very glad you found the videos useful. I have organised all the Dot Net & SQL Server videos in to playlists, which could be useful to you ru-vid.complaylists?view=1&sort=dd If you need DVDs or to download all the videos for offline viewing please visit www.pragimtech.com/kudvenkat_dvd.aspx Slides and Text Version of the videos can be found on my blog csharp-video-tutorials.blogspot.com Tips to effectively use my youtube channel. ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-y780MwhY70s.html If you want to receive email alerts, when new videos are uploaded, please subscribe to my youtube channel. ru-vid.com If you like these videos, please click on the THUMBS UP button below the video. May I ask you for a favor. I want these tutorials to be helpful for as many people as possible. Please share the link with your friends and family who you think would also benefit from them. Good Luck Venkat
@sudhakarjampanna3945
@sudhakarjampanna3945 4 года назад
@@Csharp-video-tutorialsBlogspot - Do you provide training on SQL SERVER DBA /Azure DBA..or any videos on Clustering and login users /different types of roles or access in sql. my number 9030014648
@bahadirezici
@bahadirezici 5 лет назад
God bless you!
@aprillong4805
@aprillong4805 2 года назад
Thank you! After many videos, I finally get it! 👍🏾🎉🙏🏾
@yahyamlaouhi9508
@yahyamlaouhi9508 4 года назад
man you r hell of a teacher thanks
@mohamedabbes6064
@mohamedabbes6064 2 года назад
Thank you so much, you videos are addictive great explanation.
@AbhishekKumar-vo7wr
@AbhishekKumar-vo7wr 5 лет назад
Wow. You explain like a G!!! Gang gang. God bless
@Quangnguyen1696
@Quangnguyen1696 3 года назад
Save me from some headaches. Thank you !
@grreddy2811
@grreddy2811 2 года назад
Nice teacher I have ever seen
@rajeshkumar-ii8bb
@rajeshkumar-ii8bb 2 года назад
Your explanation was amazing....Tq very much
@shahidurislam4646
@shahidurislam4646 4 года назад
Thank you Sir, easily the best tutorial teacher
@cool-as-cucumber
@cool-as-cucumber 8 лет назад
Great channel, please keep doing these videos. You are the teacher i never had.
@kebincui
@kebincui 2 года назад
Thank you so much for sharing, very clear explanation 🌹👍👍
@Oxidado86
@Oxidado86 5 лет назад
me si sirvio bastante, a pesar de estar en ingles , logre enteder la idea del ROW NUMBER . Muchas gracias
@GenerallyGoodMusic
@GenerallyGoodMusic Год назад
Thank you, love your videos.
@jackfrost8969
@jackfrost8969 7 месяцев назад
Excellent explanation.
@tusharmehrotra647
@tusharmehrotra647 2 года назад
Great videos, big thanks to venkat!
@ravishankar0901
@ravishankar0901 4 года назад
Well explained, going forward I am going to search any sql issue with your name on youtube.
@gosmart_always
@gosmart_always 5 лет назад
Thank you Venkat. You are helping me a lot. Please make a video how we can rollback our database to a given point.
@brindhaganesan3580
@brindhaganesan3580 6 лет назад
Cystal clear explanation!
@ramachandranm4210
@ramachandranm4210 9 лет назад
nice sir..i watch your ASP and SQL video Series
@FaeUtero
@FaeUtero 3 года назад
Thanks again for a great tutorial.
@seanm8362
@seanm8362 4 года назад
This is very informative. Thank you so much!
@mansimishra19
@mansimishra19 2 года назад
Very well explained! Thank you
@jitsharma88
@jitsharma88 Год назад
thanks . very helpful
@tempura_edward4330
@tempura_edward4330 3 года назад
Great explanation! Thank you
@Alam_Syed
@Alam_Syed 5 лет назад
I was looking for this thank you so much
@ashrafomer5297
@ashrafomer5297 5 лет назад
Thanks Venkat it was well don Tutorial
@Toofan2704
@Toofan2704 4 года назад
Very good tutorial Venkat :) thank you
@loayoraby674
@loayoraby674 5 лет назад
thanx alot your videos is helping me
@kevinjia1984
@kevinjia1984 3 года назад
Great video, thanks a lot !
@Kamil0289
@Kamil0289 6 лет назад
very helpful thanks kudvenkat!
@BeingSam7
@BeingSam7 Год назад
When we are populating the result set in subquery which is captured within CTE and then we are deleting only from that CTE itself, then how come the original table employee is getting affected? I have again watched the part where you have explained CTE but didn't understand this. Could you kindly help. Ohh and by the way the whole series is very helpful, KUDOS!! to you Venkat for helping so many people with your great knowledge and impeccable teaching talent!!
@jaspreetdandiwal
@jaspreetdandiwal 6 лет назад
very good video, flawless
@SinhaFps
@SinhaFps 4 года назад
Great explanation! Thx!
@hungcao1342
@hungcao1342 2 года назад
nice !
@meanmachineYT09
@meanmachineYT09 6 лет назад
This helped me a lot, thanks!
@20thCenturyFav
@20thCenturyFav 8 месяцев назад
very well explained, thank you, where's your tip cup lol
@karnav43
@karnav43 2 года назад
Hi Venkat, Thanks for these tutorials. One request. Can you create some tutorials on big query? Thanks
@chandrakumarreddyvennapusa7806
@chandrakumarreddyvennapusa7806 3 года назад
Fantastic:)
@huiqingxu5286
@huiqingxu5286 5 лет назад
You are amazing!
@dosovi4548bustayes
@dosovi4548bustayes 9 лет назад
Great
@dollarmenu9618
@dollarmenu9618 6 лет назад
well explained
@JohnWick-zv2mr
@JohnWick-zv2mr 9 лет назад
thank you very good
@evgenyr7127
@evgenyr7127 6 лет назад
Great!! Thanks!
@ashutoshhegde7290
@ashutoshhegde7290 6 лет назад
thank you Venkat Sir
@gautamsham7291
@gautamsham7291 3 года назад
Please add plsql tutorial videos as well!
@peternguyen9382
@peternguyen9382 Год назад
Hello Venkat, i dont understand why we delete the data from CTE it delete the data in the real table. I thought the data from CTE is the difference from the table. ?
@Archanaarchu-nd3xu
@Archanaarchu-nd3xu 10 дней назад
Whether can v hav row_number as auto increment without repeating. First time if I m executing the select stt i should get 1,2,3 n if I m executing 2nd time i should get 4,5.
@samirkumar6180
@samirkumar6180 3 года назад
Hello sir, pls make video on table partitioning and their concept...this is something important which is not made yet
@raqibulAlam-su3jo
@raqibulAlam-su3jo 9 лет назад
Thanks.
@nssramya8792
@nssramya8792 2 года назад
superb sir. I have one doubt how to partition the row_number by alphabetical order sir
@DB-sf1hy
@DB-sf1hy 4 года назад
How come when you delete from the CTE you also delete from the original table?
@angelmeist2652
@angelmeist2652 Год назад
can you explain in what order is the male part of the row number assigned after executing the commend... "Tom, Ron, Ben, Todd, Mark, John' does not come as the same order in the original table and it is not in any asc or desc order neither.
@kartikmondal4933
@kartikmondal4933 5 лет назад
Thank u sir.
@rifaqatullah2379
@rifaqatullah2379 7 лет назад
Wonderful
@wasimbader9170
@wasimbader9170 8 лет назад
I have sent an email and still waiting for reply. Thumbs up for this video.
@venkataashok9460
@venkataashok9460 2 года назад
its maximum row size exceeds the allowed maximum of 8060 bytes. INSERT or UPDATE to this table will fail if the resulting row exceeds the size limit. how to over come this warning
@NelsonZavala0509
@NelsonZavala0509 4 года назад
Hi it is possible to update all the results send by the row_number with another valure from another table ?
@aruneshdillikar4633
@aruneshdillikar4633 3 года назад
what is employee cte is that the table name?
@MrPlockey
@MrPlockey 7 лет назад
I have seen several of you videos that reference Partition. What does that do?
@mahendrasinghbaghel3039
@mahendrasinghbaghel3039 7 лет назад
can we use one more where clause with row number...?
@themachine225
@themachine225 6 лет назад
Hi, thanks for the video, this seems like a very simple function, i have tried it and it seems like its working by its actually returning an empty column, this is my exact code: ROW_NUMBER() OVER (PARTITION BY orddet_nl.invnum ORDER BY orddet_nl.invnum ASC) AS LineReference, i dont get any error messages or anything, but it just brings an empty column, any ideas why? Thanks
@ManishKumar-qx1kh
@ManishKumar-qx1kh 3 года назад
query seems ok can you please post ur sample data so that we can help.
@jessejacob1850
@jessejacob1850 3 года назад
I tried it but got an error message saying no column as rownumber
@leninmishra
@leninmishra 8 лет назад
Hi Venkat, I have data that has following rows.... 2934046 Kellogg’s Share Your Breakfast 74672 2407522 Kellogg?s Share Your Breakfast ACTIVE 2015-09-01 9999-12-31 2934046 Kellogg?s Share Your Breakfast 74672 2407522 Kellogg?s Share Your Breakfast ACTIVE 2015-09-01 9999-12-31 You can see that both rows are the same except for the question mark in the second row. I have to remove such rows from my table. I was trying to use row_number for this, but it doesn't work. Is there any way i can rank such rows based on the characters in my second column...
@hgoodman9
@hgoodman9 8 лет назад
What if you only want to return the row with the max row number?
@archrodney
@archrodney 7 лет назад
-- This query will give you 1 row with the max row number: SELECT TOP 1 *, ROW_NUMBER()OVER(PARTITION BY ID ORDER BY ID) AS RowNumber FROM Employees ORDER BY RowNumber DESC; -- This query will give you ALL rows with the max row number: WITH RowNumberCTE AS ( SELECT *, ROW_NUMBER()OVER(PARTITION BY ID ORDER BY ID) AS RowNumber FROM Employees ) SELECT * FROM RowNumberCTE WHERE RowNumber = (SELECT TOP 1 * FROM (SELECT ROW_NUMBER() OVER (PARTITION BY ID ORDER BY ID) AS RowNumbers FROM Employees) DerivedTable ORDER BY RowNumbers DESC) -- I know it's not a nice piece of code but it does the job.
@hgoodman9
@hgoodman9 7 лет назад
archrodney thanks
@veenitkarkhanis338
@veenitkarkhanis338 5 лет назад
Hey guys help me how to find odd rows and even rows
Далее
Rank and Dense Rank in SQL Server
10:08
Просмотров 240 тыс.
Over clause in SQL Server
9:13
Просмотров 240 тыс.
54 How to use multiple CTE in SQL Server
7:44
Просмотров 4 тыс.
Learn GROUP BY vs PARTITION BY in SQL
14:03
Просмотров 37 тыс.
Window functions in SQL Server
11:00
Просмотров 220 тыс.