I am trying to create some sort of couple matching. I have 2 tables namely Boy and Girl which both have the same fields which is shown below
ID
Name
Age
Birthdate
Bith Sign
Hobbies
Interests
I want to rank them according to the sample fields I provided above.
In the web form, the fields for Birth Sign, Hobbies and Interests are in drop down format so that I can limit the answer of the users therefore the matching process will be easier i guess.
I split up the data based on their gender and later on I plan to join the two tables together for the matching but right now I do not have any idea on what will be my sql query for the matching process.
Now I am having a difficulty on how can I display the result of the matching and the result must be in ranking order.
For example the result should somehow look like this.
| BOY | GIRL | RANK |
+====+====+=====+
| John | Sarah | 1 |
| John | Kate | 2 |
| John | Sammy | 3 |
| John | Donna | 4 |
| John | Tanya | 5 |
Any idea on how can this be done? Thanks
query matching
Moderator: General Moderators
Re: query matching
It'll greatly help if you can quantify (ie, give a number to) how close of a match two people are. Can you do that yet? What's the formula?
-
greedyisg00d
- Forum Commoner
- Posts: 42
- Joined: Thu Feb 12, 2009 2:48 am
Re: query matching
right now I do not have a working formula and just trying things out. Can you give me an example how to match the data from two tables and the result will be shown in a single table. Thanks
Re: query matching
The query can only represent the logic you use to match. You can't write a query without figuring out first how the matching would take place.. you can't program without knowing what you want the computer to do.