Hi,
I have the following query:
SELECT DISTINCT(glinks_ClickTrack.LinkID) FROM glinks_ClickTrack
JOIN glinks_Links ON glinks_ClickTrack.LinkID = glinks_Links.ID
WHERE ClickType = "Hits"
ORDER BY glinks_ClickTrack.Created LIMIT 5;
What I need to do, is also get the values from the glinks_Links table. I tried:
SELECT glinks_Links.*,DISTINCT(glinks_ClickTrack.LinkID) FROM glinks_ClickTrack
JOIN glinks_Links ON glinks_ClickTrack.LinkID = glinks_Links.ID
WHERE ClickType = "Hits"
ORDER BY glinks_ClickTrack.Created LIMIT 5;
...but that didn't work.
Is there a way to achieve what I'm trying to do?
TIA!
Andy
I have the following query:
SELECT DISTINCT(glinks_ClickTrack.LinkID) FROM glinks_ClickTrack
JOIN glinks_Links ON glinks_ClickTrack.LinkID = glinks_Links.ID
WHERE ClickType = "Hits"
ORDER BY glinks_ClickTrack.Created LIMIT 5;
What I need to do, is also get the values from the glinks_Links table. I tried:
SELECT glinks_Links.*,DISTINCT(glinks_ClickTrack.LinkID) FROM glinks_ClickTrack
JOIN glinks_Links ON glinks_ClickTrack.LinkID = glinks_Links.ID
WHERE ClickType = "Hits"
ORDER BY glinks_ClickTrack.Created LIMIT 5;
...but that didn't work.
Is there a way to achieve what I'm trying to do?
TIA!
Andy