Click here to Skip to main content
15,890,557 members
Home / Discussions / Database
   

Database

 
GeneralRe: Subquery returns more than 1 row Pin
Jassim Rahma24-Oct-12 10:38
Jassim Rahma24-Oct-12 10:38 
GeneralRe: Subquery returns more than 1 row Pin
fjdiewornncalwe24-Oct-12 10:42
professionalfjdiewornncalwe24-Oct-12 10:42 
GeneralRe: Subquery returns more than 1 row Pin
Jassim Rahma24-Oct-12 10:46
Jassim Rahma24-Oct-12 10:46 
GeneralRe: Subquery returns more than 1 row Pin
fjdiewornncalwe24-Oct-12 10:49
professionalfjdiewornncalwe24-Oct-12 10:49 
GeneralRe: Subquery returns more than 1 row Pin
Jassim Rahma24-Oct-12 10:52
Jassim Rahma24-Oct-12 10:52 
GeneralRe: Subquery returns more than 1 row Pin
fjdiewornncalwe24-Oct-12 11:03
professionalfjdiewornncalwe24-Oct-12 11:03 
Questionlocking on select Pin
dabuskol20-Oct-12 19:37
dabuskol20-Oct-12 19:37 
AnswerRe: locking on select Pin
Eddy Vluggen21-Oct-12 2:22
professionalEddy Vluggen21-Oct-12 2:22 
dabuskol wrote:
I have a SP that calculates data based on criteria, the result were % and duration. It takes 8-10 seconds before it displays the result.

You *could* use the SP to retrieve the bare results, and do the calculations in code (on the client) - that would take some work of the server. Post the SP here, and we could have a look at optimizing it.

dabuskol wrote:
The problem is when more users are trying to generate the report, it seems that it takes more time.

That's not a problem, but expected behavior; more requests for the database means simply more work.

dabuskol wrote:
I don't have any locking on my select nor update.

What is the best practice to resolve it?

Locking wouldn't help much; you'd still get a time-out if the query does not return within the set timeout-period. Depending on your needs, you could have it timeout after half an hour.

Still, best idea would be to move the calculations, limit the joins and optimize the query.
Bastard Programmer from Hell Suspicious | :suss:
if you can't read my code, try converting it here[^]

AnswerRe: locking on select Pin
Mycroft Holmes21-Oct-12 13:05
professionalMycroft Holmes21-Oct-12 13:05 
AnswerMessage Closed Pin
22-Oct-12 2:20
Aadhar Joshi22-Oct-12 2:20 
GeneralRe: locking on select PinPopular
Eddy Vluggen22-Oct-12 2:43
professionalEddy Vluggen22-Oct-12 2:43 
GeneralMessage Closed Pin
22-Oct-12 2:49
Aadhar Joshi22-Oct-12 2:49 
GeneralRe: locking on select PinPopular
Eddy Vluggen22-Oct-12 2:58
professionalEddy Vluggen22-Oct-12 2:58 
GeneralMessage Closed Pin
22-Oct-12 3:10
Aadhar Joshi22-Oct-12 3:10 
GeneralRe: locking on select Pin
Eddy Vluggen22-Oct-12 3:14
professionalEddy Vluggen22-Oct-12 3:14 
GeneralRe: locking on select Pin
Aadhar Joshi22-Oct-12 3:18
Aadhar Joshi22-Oct-12 3:18 
GeneralRe: locking on select Pin
Eddy Vluggen22-Oct-12 3:31
professionalEddy Vluggen22-Oct-12 3:31 
GeneralRe: locking on select Pin
Eddy Vluggen22-Oct-12 5:16
professionalEddy Vluggen22-Oct-12 5:16 
GeneralRe: locking on select PinPopular
Aadhar Joshi22-Oct-12 18:05
Aadhar Joshi22-Oct-12 18:05 
GeneralRe: locking on select Pin
The Sql Coder22-Oct-12 20:01
The Sql Coder22-Oct-12 20:01 
GeneralRe: locking on select Pin
Eddy Vluggen22-Oct-12 23:33
professionalEddy Vluggen22-Oct-12 23:33 
GeneralRe: locking on select Pin
Aadhar Joshi22-Oct-12 23:48
Aadhar Joshi22-Oct-12 23:48 
GeneralRe: locking on select Pin
Mycroft Holmes23-Oct-12 0:36
professionalMycroft Holmes23-Oct-12 0:36 
AnswerRe: locking on select Pin
kankeyan26-Oct-12 0:58
kankeyan26-Oct-12 0:58 
AnswerRe: locking on select Pin
Hitesh R5-Nov-12 22:42
Hitesh R5-Nov-12 22:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.