Hi
i have a table 'forum' with
id - topic - user - datum - comment
What i want is a table with only the max date with the corresponding user grouped by the topics
so i can set the last message was post on ... by ...
i found the solution in SQL:
SELECT topic, user, datum
FROM forum t1
WHERE...
thx again but there is still an error.
(date = datum & table = forum)
SELECT topic, user, datum
FROM forum t1
WHERE datum = (
SELECT MAX( datum )
FROM forum
WHERE topic = t1.topic
)
You have an error in your SQL syntax near 'SELECT MAX( datum ) FROM forum WHERE topic =...
Thanks,
But i don't think i explain it that clear..
i have a table with
id - topic - user - date - comment
What i want is a table with only the max date with the corresponding user grouped by the topics
so i can set the last message was post on ... by ...
Hope tis will clear up a bit...
Hi,
I'am searching for a few day to a spec. query can someone help me?
table A:
R1 R2 R3
a - 6 - z
d - 2 - p
a - 5 - y
g - 8 - w
d - 6 - w
I need:
R1 R2 R3
a - 6 - z
d - 6 - w
g - 8 - w
I 've allready try this query
Select R1,max(R2),R3 from a group by R1
R1 R2 R3
a - 6 - z
d - 6 - p...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.