Hello. I have few SQL queries. Something like this:
I have to create these queries if data structure is like this:Code:number of patients born on Januray 1st, 2000 number of patients born before Januray 1st, 2000 number of patients having firstname "JOHN" distribution patients per birth year distribution of firstnames
What query should I do on last requests (distribution patients per birth year) ? Grouping data by birth year ?Code:P00003542,JOHN^SMITH,19960124,M P00002888,BILLY^STANLEY,20050903,U P00006888,HRO^ELLEN,20040314,U
And I have another task then:
Reduce the computation time of the queries above using indexes
What should I do in this case on queries from above ?




Reply With Quote
