Stored procedures DONOT increase performance(.NET and SQL training video)

Stored procedures DONOT increase performance(.NET and SQL training video)

62,740 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

@girish9841
@girish9841 - 10.12.2023 08:38

Best explanation sir

Ответить
@DummyFace123
@DummyFace123 - 25.04.2023 18:26

In general you’ll end up having a much easier time hypertuing a database that’s all stored procedure, especially on complex stuff, there’s no other option that to perform the complex work in the memory of the the actual machine instead of from a remote webserver. As well as having a machine with tools and a language fine tuned to dealing with relational datamodels.

Ответить
@hrudayaranjanmohanty2689
@hrudayaranjanmohanty2689 - 22.12.2021 19:31

Very use full video sir..

Ответить
@sumitkumarsingh8179
@sumitkumarsingh8179 - 23.12.2019 15:40

But when parameters changed then......

Ответить
@gkmishra2009
@gkmishra2009 - 21.09.2019 17:14

I given interview and got question on below please explain

Asynchronous programming how achieve in #
Reflection
Extension Method
We pass data from one app to another how we secure the data
How secure Channel in network
Collection can we use in multi thread env
Concrete Dictionary
mediatype
app/json and text/json
what are Azure Services you used
SOLID
Benefits of View
How delete Views work

Ответить
@rahulraj3898
@rahulraj3898 - 09.07.2019 07:43

Video is not clear about the cache for plane sql statement . Lets check by changing the parameters

Ответить
@vikrampatel4033
@vikrampatel4033 - 24.03.2019 11:46

Nice. I am using linq2sql

Ответить
@sumitrakumar3956
@sumitrakumar3956 - 05.09.2018 04:13

nice vidoe

Ответить
@breaktime6125
@breaktime6125 - 25.04.2018 08:58

your thought is wrong. if you pass parameter value both sp and normal query it will show different
change parameter and pass parameter:
SP--> cach insert ,catch hit,catch hit,catch hit,catch hit,catch ..........
nomal query --> cach insert,catch hit,cach insert,catch hit,cach insert,catch hit,cach insert,catch hit..

Ответить
@0Pain0Gain
@0Pain0Gain - 07.10.2017 00:03

if you keep changing the username and password (text inputs) then there will be multiple plans created for each dynamic sql (since the hash will be different each time...not ideal..will result in plan cache pollution)...better use parameters and sp_executesql or stored procedures...also this way of string concatenation poses a sql injection threat...ORMs typically send out parameterized sp_executesql calls (can be verified by the Profiler) and therefore can re-use plans from the cache (that's why they are faster)...but with anything else it can be misused too :-)

Ответить
@tseringlobsang1789
@tseringlobsang1789 - 02.08.2017 12:48

Your title is a bit misleading because, basically the ORM frameworks kill the performance.

Ответить
@satishnagotkar886
@satishnagotkar886 - 26.07.2017 12:40

Nice video - good effort to describe the things

Ответить
@moustafa12210
@moustafa12210 - 24.04.2017 23:10

You just tested, that sp query and inline query are being cached. but you didn't measure all the pipeline performance for each one starting from parsing, compiling, analysing, optimising, etc. also simple query not enough to be a fear measurement, you should figure out many inputs and cases. finally to mention this is just query operation but what about a whole picture of crud processing in a large set of transactions scope. I disagree. sp increase performance.

Ответить
@mca47378
@mca47378 - 26.03.2017 22:14

I know your intention was to explain that there is no difference in performance if same query or proc is shot next time, it will always find plan in plan cache. But while doing so you used wrong examples and explanation. Inline query should be avoided at any point of time from app for many reasons and security being on top in it. In my view when we try to explain certain abstract of a technology in a Demo, we should be very specific about the explanation and examples to support that. Otherwise you would spend another two classes to explain that it was wrong practice OR example.

Ответить
@SpikedHairWarrior
@SpikedHairWarrior - 30.11.2016 21:50

Sps have a huge performance improvement compared to queries. Any dev can make basic valid test(this video doesn't actually test anything) and calculate the execution time and see a massive difference between them. This video should be deleted for giving junior devs the wrong idea.

Ответить
@sureshsl985
@sureshsl985 - 24.11.2016 15:31

The one more advantage I can see in using Stored Procedure is, sql injection will be avoided.

Ответить
@seankiernan6593
@seankiernan6593 - 22.07.2016 23:34

This video helped me a lot, thank you very very much :)

Ответить
@hawkbala456
@hawkbala456 - 12.02.2016 08:36

Your activity is definitely worth .. :)

Ответить
@retry51776
@retry51776 - 05.11.2015 07:32

Only simple query plan will be cache, when a complex query, cache most likely be clear within minutes.

Ответить
@GurjeetSingh-tl1yv
@GurjeetSingh-tl1yv - 11.08.2015 11:17

Nice video...removing developers misconception on stored procedures...

Ответить
@gamccoy
@gamccoy - 06.08.2015 06:29

Interesting video.  I don't agree that inline SQL is just as efficient.  If you are changing the SQL (say from method parameters), SQL Server is going to think it is a different query.  The parameterized SPROC will still read be a cache hit.  Also, the SPROC will not have the startup cost if it has been accessed within a certain amount of time.  Your test app will always have the startup penalty when using inline SQL.

Ответить
@GunaNidhiPokhrel
@GunaNidhiPokhrel - 19.06.2015 09:15

good effort to describe the things

Ответить
@hardeepsaggi140
@hardeepsaggi140 - 16.04.2015 10:49

good video to get basics straight !! thanks :)

Ответить
@Katerine459
@Katerine459 - 26.03.2015 01:49

While you neatly explained that stored procedures aren't more efficient than inline functions (in situations where what you intend to do is even possible from an inline statement... I always thought stored procedures were for things that you can't do inline)... there is one glaring problem with this video, in that the example inline SQL that you wrote is totally vulnerable to SQL Insertion, and should never be used in examples of valid code. Going by the video, the procedure route appears to still be light-years better, not because of performance, but because it uses parameters instead of allowing user-created inputs to go directly into the SQL, leaving the database wide open to hackers.

Ответить
@msushami
@msushami - 10.12.2014 07:12

Then What is the difference b/w stored procedures and inline query ???
G+

Ответить
@sabyasachideKol
@sabyasachideKol - 01.10.2014 07:12

Not agreed .. why only cached? Stored Procedure are compiled where as inline queries get compiled every time. So ofcourse performance basic SP's are better 

Ответить
@AltafHussainnagri
@AltafHussainnagri - 09.08.2014 20:15

then what is the difference. why we need to create store procedure????

Ответить
@jubinsingh931
@jubinsingh931 - 22.05.2014 12:31

hello Sir,
the way you have taught us about Stored procedure was great.......and you are absolutely right that inline queries in sql 2005 servers and onwards do the same thing what Stored procedure do(About performance).....but if we do some little bit changes  in the same query that we had previously executed like  we can give some extra space in the same previous query
 for Example "select * from Table_name" this is our previous query and the modified query is "select * from (some extra space i have given their)   Table_name"

and when we execute the modified query so the new  "Execution plan will be generate"  but if we do the same thing in the query stored in stored procedure and then execute the stored procedure then it will not create a  new "Execution plan"....it will take from cached....and then execute the query....i hope you will not mind,i just wanted to clarify the things...& if i am wrong then you are welcome to clear my myth....Thank you :)

Ответить
@srinivasrapaka4465
@srinivasrapaka4465 - 03.05.2014 21:23

nice and cool video.. realy good and helpfull to interview purpose also thank u lot

Ответить
@ukdcj
@ukdcj - 01.05.2014 19:53

hey thanks, its helpful 

Ответить
@dhirajkatekar6323
@dhirajkatekar6323 - 09.03.2014 09:12

i have a doubt that does inline query gonna make difference to the network traffic as compared to the stored procedures. If we are using inline query we need pass whole query through the network whereas in stored procedure we just need to pass parameters and procedure name if am not wrong. And disadvantage to using inline query is that whenever we need to make certain changes to query we will have to stop the application and in case of stored procedure we just have to make changes to the database which is quite efficient as per the developer point of view.

Ответить
@MFurqanKhan
@MFurqanKhan - 21.01.2014 17:40

Instead of getting into debate how parameters work for inline query try executing an inline query with different parameters and see what profiler shows. Then try executing a SP with different parameters and then see what profiler shows.
I am sure your results will enlighten us all.
According to my results on SQL Profiler "Cache Insert" is called for inline query each time parameters are changed. Whereas for SP "Cache Hit" is called each time parameters are changed except for first time.

Ответить
@mitesh7272
@mitesh7272 - 26.09.2013 19:04

nice work.....

Ответить
@doug65536
@doug65536 - 02.08.2013 14:46

Let's hope the user doesn't enter this in the user name field: '; delete from users; --

Ответить
@swanky234
@swanky234 - 20.07.2013 20:47

Tnx for these videos !

Ответить
@swanky234
@swanky234 - 20.07.2013 20:47

its Cool ...!

Ответить
@manurajbharall
@manurajbharall - 31.05.2013 09:04

The same concept is work for Oracle also, or there may be same different mechanism in Oracle.

Ответить
@jzhuo
@jzhuo - 06.05.2013 13:11

very cool, definitely didn't know that one.

Ответить
@vijaykondal2063
@vijaykondal2063 - 28.04.2013 14:58

It really clear my doubt. thanks

Ответить
@prashantjadhav5440
@prashantjadhav5440 - 20.04.2013 10:57

thanks for sharing

Ответить
@stevesmith2165
@stevesmith2165 - 12.04.2013 09:48

Good video.

Ответить
@thesqaanalyst
@thesqaanalyst - 12.03.2013 01:00

Great video and explanation. Thanks.

Ответить
@iampaddyofficial
@iampaddyofficial - 01.03.2013 16:21

very useful information... Thanks Shiv

Ответить
@Eshamohit
@Eshamohit - 28.02.2013 10:41

very good explanation.

Ответить
@khaled344
@khaled344 - 26.11.2012 09:27

Well said, thanks

Ответить
@msg2swaroop
@msg2swaroop - 17.09.2012 09:40

thanks for info...

Ответить
@MiddleEasternInAmerica
@MiddleEasternInAmerica - 03.09.2012 12:32

all my thanks is all I have to give. thanks millions

Ответить
@MFurqanKhan
@MFurqanKhan - 27.08.2012 13:55

I think scenario given by @paulorocha1975 is enough to decline the logic explained in this video. i.e. inline query will insert cache each time it's parameter value is modified whereas SP will always use existing cache regardless of parameter values.

Ответить
@paulorocha1975
@paulorocha1975 - 10.08.2012 12:14

Hmm, how will it behave if you send different combinations of usernames and passwords to the stored procedure and to the inline SQL? Won't you get a different hash value every time you run the inline sql? If one wants to use inline sql would't it be better to just use parametrized queries?

Ответить