HestonJames
Programmer
Hello Guys,
Looking for a little help forming this query as the concept is currently confusing me. The end goal is to pull data which I can use to create a 'tag' or 'keyword' cloud.
I have three tables which look like this:
Media
------
Media_ID
Media_Lnk_MediaTag
------------------
Media_ID
MediaTag_ID
MediaTag
--------
MediaTag_ID
TagText
What I want to do it pull all the MediaTag's for a given Media_ID record along with a calculated percentage popularity for the MediaTag against any other Media_IDs is has relationships with.
Does that make sense? So for instance if the count of relationships to other media looks something like this:
TagText | Count_Of_Relationships_T
ther_Media
---------------------------------------------
Hello | 5
Goodbye | 5
Hello Again | 10
Then it would return me a record set like this to me:
TagText | Percentage_Of_Relationships_T
ther_Media
---------------------------------------------
Hello | 25%
Goodbye| 25%
Hello Again | 50%
I'm sorry if that's not a particularly good explanation, if you have any questions then please shoot away and I'll try my best to answer them.
Cheers guys, really appreciate this.
Heston
Looking for a little help forming this query as the concept is currently confusing me. The end goal is to pull data which I can use to create a 'tag' or 'keyword' cloud.
I have three tables which look like this:
Media
------
Media_ID
Media_Lnk_MediaTag
------------------
Media_ID
MediaTag_ID
MediaTag
--------
MediaTag_ID
TagText
What I want to do it pull all the MediaTag's for a given Media_ID record along with a calculated percentage popularity for the MediaTag against any other Media_IDs is has relationships with.
Does that make sense? So for instance if the count of relationships to other media looks something like this:
TagText | Count_Of_Relationships_T
---------------------------------------------
Hello | 5
Goodbye | 5
Hello Again | 10
Then it would return me a record set like this to me:
TagText | Percentage_Of_Relationships_T
---------------------------------------------
Hello | 25%
Goodbye| 25%
Hello Again | 50%
I'm sorry if that's not a particularly good explanation, if you have any questions then please shoot away and I'll try my best to answer them.
Cheers guys, really appreciate this.
Heston