Link to home
Start Free TrialLog in
Avatar of czechmate1976
czechmate1976Flag for United Kingdom of Great Britain and Northern Ireland

asked on

Can someone help with a mysql query??

I have a database (of which diagram I am attaching to this question) and I can't figure out how to get a list of clinics with the total of salary paid to staff in each clinic ie. for example

1. clinic         £286000
2. clinic         £411000
3. clinic         £136000
4. clinic         £171000
DATA-DICTIONARY-FOR-TRAVEL-CLINI.gif
ASKER CERTIFIED SOLUTION
Avatar of Roger Baklund
Roger Baklund
Flag of Norway image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of czechmate1976

ASKER

Brilliant! I totally fortgot the group by... Points are yours and thanks.. just one little thing: How do I format it to put the pound sign with the number (£)? Thanks a lot
This should output a pound sign in front of the number: concat('£',sum(stafftype_salary))
SORRY, you are right!! and thanks again..
Thanks a lot! I totally forgot about the Group by... my only excuse is I am a beginner. Once again, thanks!