Sql how many joins is too many
Active 8 years, 5 months ago. Viewed 16k times. So, the questions are: What could possibly cause the big improvement?
Is it a standard procedure to split big joins into smaller? Grade, TC. TestCampaignId, T. TestSetId ,TL. TestId ,TSK. CategoryId ,TT.
SectionNo ,TL. Difficulty ,TQ. StudentId ,TS. ClassId ,RA. SubjectId ,TQ. Redizo ,TT. ViewCount ,TT. SpentTime ,TQ. PersonId And RA. ProcessedOn is not null -- ne vsechny, jen dokoncene And TL. ShownOn is not null And TS. TestId ,TL. Difficulty -- prevod na A5, B4, B ClassId ,TS. Id ,TL. Grade, FR1. TestCampaignId, FR1. TestSetId ,FR1. SectionNo ,FR1. StudentId ,FR1. ClassId ,FR1. Grade, FR2. TestCampaignId, FR2. TestSetId ,FR2. TestId ,FR2. SectionNo ,FR2. Difficulty ,FR2. TestletName ,TQ.
StudentId ,FR2. Redizo ,FR2. ViewCount ,FR2. TestAdaptationId ,FR2. TaskId ,FR2. Guid ,FR2. Improve this question. Ondrej Peterka Ondrej Peterka 2 2 gold badges 6 6 silver badges 10 10 bronze badges.
It's just not the magic bullet that people seem to think it is. Stack Overflow for Teams — Collaborate and share knowledge with a private group. Create a free Team What is Teams? Learn more. SQL too many joins limitations- what will break and how Ask Question.
Asked 5 months ago. Active 3 months ago. Viewed 26 times. Adding activities isn't a problem because no activity uses all 70 available data sets.
Improve this question. Craig Almond Craig Almond 1, 7 7 silver badges 15 15 bronze badges. Add a comment. Active Oldest Votes. So, after talking to colleagues my understanding is Here to learn, so feel free to tell me where I'm wrong with this. This is a win in my books. I also killed every running query manually that was stuck in the Statistics phase.
This brought down the CPU. The 53 JOIN query that used to fail to complete, now completes in ms. Not fast, but a damn sight faster than several days.
0コメント