which one is faster execute reader, scalar, execute non
query ?
Answer Posted / peter
What is faster:
ExecuteNonQuery("INSERT INTO...; INSERT INTO...; INSERT
INTO");
or
ExecuteNonQuery("INSERT INTO...")
ExecuteNonQuery("INSERT INTO...")
ExecuteNonQuery("INSERT INTO...")
I hope you see my point. Of course it is not a matter of
only three inserts, but maybe 200 - and then I would like
to know if I can save time by adding the INSERT-strings to
one big string and only fire off one ExecuteNonQuery.
I was thinking of coding a test to check, but if some of
you have already done this or just know which is faster,
please let me know.
Thanks
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
What is session object? Describe in detail.
Describe how ASP.NET maintains process isolation for each Web application?
What is asp according to you?
How can you use a custom controls in ASP.NET application?
Can I read the hard disk serial # of the client computer using asp.net?
Can you set which type of comparison you want to perform by the comparevalidator control?
What parameters can you pass in the url of the api? Can get and post use the same url?
Explain Session state management options in ASP.NET.
What are the event handlers that we can have in global.asax file?
What is another word for redirect?
Explain how is the asp.net mvc architecture different from others? : asp.net mvc
What is the difference between an htmlinputcheckbox control and an htmlinputradiobutton control?
What are the two Layouts supported by a Web form in ASP.NET?
How does session authentication work?
Describe the diffeerence between inline and code behind?