Help poor Sara with this code

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
anasgha
Forum Newbie
Posts: 4
Joined: Mon May 21, 2007 9:30 pm

Help poor Sara with this code

Post by anasgha »

Hello everybody,
I am stuck in this problem. if you can help that will be highly appreciated.

I have a table conatins information about players, each player has certain scores in every possition, and scores in every team.
I can not modify the table.

this is the table

Players table

Position Teams
School name
Defender Striker Midfielder Goalkeeper Team1 Team2 Team3 Team4
A Tomas 12 85 71 15 10 74 100 38
A Alex 1 3 11 4 09 55 2 23
B Carlos 84 51 20 40 45 48 42 52
B Jack 91 10 42 38 46 16 18 13
B John 99 43 17 78 99 88 53 12
C Sami 18 15 42 56 19 14 62 26
D Tony 37 82 37 42 43 17 64 24
D Peter 59 16 17 27 72 22 17 14
D Jemy


1-List players whose highest scores are (Goalkeeper)


2- List players whose highest scores are(Defender), if the two are from the same school choose the highest the one with the highest score.


3- List players whose highest scores are (Striker) Or team is (team2)



4- List players whose highest scores are (Striker) Or team is (team2), if there are more than one from the same school please choose the one with the highest score.


Please if you know the answer tell me ? I am really in need.

Sara
bdlang
Forum Contributor
Posts: 395
Joined: Tue May 16, 2006 8:46 pm
Location: Ventura, CA US

Post by bdlang »

Welcome to the forums.

This is the PHP forum. Please have your thread moved to the database forum, and while you're at it, provide a more relevant title and a few more details (are you working with MySQL? etc).

A gentle introduction to SQL
User avatar
Luke
The Ninja Space Mod
Posts: 6424
Joined: Fri Aug 05, 2005 1:53 pm
Location: Paradise, CA

Post by Luke »

moved to databases :arrow:
User avatar
Ind007
Forum Newbie
Posts: 14
Joined: Fri Dec 01, 2006 12:39 am
Location: India

Post by Ind007 »

It needs lot of queries if you don't split it into multiple tables.
Please go through the Normalization Norms
anasgha
Forum Newbie
Posts: 4
Joined: Mon May 21, 2007 9:30 pm

Post by anasgha »

the homework is as it is.

do you think I am allowed to modify the table.

there are still two problems 1) I don't know how to normalize the database 2) I am required to use this table, not creating new table.


I am still waiting fo an answer!!

Please if any of you know the answer, Please help.

Sara
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Descriptive subjects

Post by feyd »

"Sara," please update the thread's subject to be descriptive.
[url=http://forums.devnetwork.net/viewtopic.php?t=30037]Forum Rules[/url] Section 1.1 wrote:2. Use descriptive subjects when you start a new thread. Vague titles such as "Help!", "Why?" are misleading and keep you from receiving an answer to your question.
bdlang
Forum Contributor
Posts: 395
Joined: Tue May 16, 2006 8:46 pm
Location: Ventura, CA US

Post by bdlang »

anasgha wrote:the homework is as it is.

do you think I am allowed to modify the table.

there are still two problems 1) I don't know how to normalize the database 2) I am required to use this table, not creating new table.


I am still waiting fo an answer!!

Please if any of you know the answer, Please help.

Sara
Aside from what has already been mentioned, please tone down the attitude. We're here to help on a volunteer basis, and we're not necessarily inclined to do your homework for you.

If you can read through some tutorials (note the link I provided in my first post) and attempt to actually do the work assigned to you (shock, I know), then post back what you're having trouble with and we will do our best to help. Otherwise, you might request a bid and pay one of us to do the work for you.
anasgha
Forum Newbie
Posts: 4
Joined: Mon May 21, 2007 9:30 pm

Post by anasgha »

Hello, I will pay you to do it.

I am not forcing people to help!
the reason for such websites is to exchange the help. If you can provide the help for free, write it down here. If you want to help but paid, Say I will help but after being paid.
your way of writing tells alot about your personality. You don't have the right to criticise my request for help here as long as it was very polite with other people on the contrary of yours.


please if anyone can help, I would pay for the help.


PLEASE, IF YOU DON'T KNOW THE ANSWER. OR NOT WELLING TO PROVIDE AN ANSWER. DO NOT BOTHER READERS with NONSENSE.

Thanks

Sara
Post Reply